Documentation for Confluence 5.4.
Documentation for Confluence OnDemand and earlier versions of Confluence is available too.

Skip to end of metadata
Go to start of metadata

The Page Index macro creates a hyperlinked alphabetical index of all page titles within the current space.

The top section of the index contains a cell for each letter of the alphabet, with cells for numbers and symbols. Each cell indicates how many pages are in the corresponding list.

The lower section contains lists of page titles followed by the first few sentences of content on that page.

Each letter, number or symbol in the top section is hyperlinked to the corresponding cell in the lower section. Each page title in the lower section is hyperlinked to the page in the space.

Screenshot: Page Index macro (partial view)


Using the Page Index macro

To add the Page Index macro to a page:

  1. In the Confluence editor, choose Insert > Other Macros.
  2. Find and select the required macro.

Speeding up macro entry with autocomplete: Type { and the beginning of the macro name, to see a list of suggested macros. Details are in Using Autocomplete.

To edit an existing macro: Click the macro placeholder and choose Edit. A macro dialog window will open, where you can edit the parameters of the macro.

This macro accepts no parameters.

 

Code examples

The following examples are provided for advanced users who want to inspect or edit the underlying markup for a Confluence page. 

Macro name: index

Macro body: None.

Parameters: None.

Storage format example

Wiki markup example

  • No labels

15 Comments

  1. Anonymous

    Is there a possibility of adding an


    macro which indexes just those pages which are "children" to the page in which the macro is added

    1. I am sorry, it seems that there is no such feature available in Confluence. You may want to raise a new feature request regarding your query to

      Cheers,

    2. Anonymous

      Did you add this as a feature request? I would personally like to see this functionality too!

      1. This seems to be a similar feature request. You can vote/comment on that with your suggestions.

        Cheers,
        Mark

  2. why does it say "!@#$" in the last field? is there anyway to get rid of it?

    1. Any page titles beginning with a symbol such as '@', '$', etc will appear in that field. There is no way to hide it as far as I know - you could raise it as an improvement request at http://jira.atlassian.com.

      Cheers,
      Mark

  3. Any way to control the column widths on the space index - I'm also using the tree navigation on the left and it's very narrow - while the column in the index are wide.

    Thanks!

    1. Hi Catherine,

      As far as I know there is no direct way to do this. I have tried to accomplish this by the use of a simple user macro. The following steps will help you to create the user macro:

      1. Go to Dashboard > Administration > User Macros
      2. Click Create a User Macro.
      3. Name your user macro anything that you want. eg: reduce
      4. Tick "Macro has a body" and Convert Macro body wiki markup to HTML
      5. Change Output to "Macro generates HTML markup"
      6. In the Template, copy and paste the following:
      7. Once you are done with that, you can use this macro to surround the {index} macro like the following:

      By specifying this, the {index} macro will only take 30% of the space that it usually takes.
      Feel free to edit the user macro to suit your requirements.

      Hope this helps.

      Cheers
      JSashi

  4. Hi! Does it work only for English alphabet? I tryed it, but seems pages with russian titles arn't included in any section.

    1. Hi Yulia,

      Yes, currently it only fully supports English alphabets, numbers as well as symbols. While testing this feature, I also tried some umlaut characters in the page title and it manages to index it if the umlaut character is in between some English alphabets. I have tried the same with Russian text, but failed.

      I would suggest you to raise an improvement request at http://jira.atlassian.com. Once you have done that, please add yourself as a watcher, vote for this feature and add your own comments to this feature request. For further details on how we include new features and improvements, you might want to read this page

      Cheers
      JSashi

  5. I'm imagining the answer is no given the lack of parameters this macro accepts but is there a way to alter the styling of the table display?

    Particularly, is it possible to have a single column display for the links rather than the default 2 column? I'm referring to the section of the table where individual links are listed with some accompanying text, not the top part with the individual letters of the alphabet.

    Additionally, is there a way of specifying the amount of text (number of words?) that are listed with each link. In the case of indexes with numerous entries the default setting can add up to a dizzying amount of text displayed on a page.

    many thanks.

    1. Hi Georgina, fir the first part of your question you can partially style the content using the spaces style-sheet and the div macro from the Content Formatting Macros. With this I use the following for mine:

      For the second part, the index macro really should obey the excerpt macro, but it doesn't, I've just created an issue for it, please vote on it if this would suit your needs.

  6. Catherine,

    You can try creating 2 column sections to control the overall width used by this macro and the tree navigation

  7. Anonymous

    I dont want the first few sentences of the page to be displayed. I just want the page names in the index. Is there a way we can remove that part?

    1. Sorry, this macro has no parameters, so it is not possible to turn off the page excerpts.