Hi,
I am programmatically creating a space with a set of pages in it. I have assumed that the pages appear in the left navigation pane in the order in whcich they were created. But the pages are not coming in that order. Infact they are not even fully alphabetical.
Is there any way to specify the ordering of pages in the left navigation pane programmatically?
Thanks,
Rajendra
Community moderators have prevented the ability to post new answers.
In the theme configuration, disable the pagetree, then add the following to the navigation pane:
{pagetree:root=@home|sort=creation}
This is entirely safe for upgrade and also completely configurable from space to space.
Further information on configuring pagetree.
See also this related answer.
It's quite easy.... first find the doctheme-x.x.x.jar file with your version of Confluence. Take a copy of it and unzip it somewhere on your local hard disk.
Then go edit the file:
In there you will find a line something like:
$helper.renderConfluenceMacro("{pagetree:root=@home}")
you want to replace it with something like
$helper.renderConfluenceMacro("{pagetree:root=@home|sort=natural}")
You then want to re-zip the file making sure the atlassian-plugin.xml is at the top level.
You can then reload the plugin back into Confluence via the Plugin Manger.
for more info on page ordering and why your pges were not in order have look at
http://confluence.atlassian.com/display/DOC/Sequential+Order+of+Pages
http://confluence.atlassian.com/display/DOC/Setting+a+Page+Family+to+Alphabetical+Order
http://confluence.atlassian.com/display/DOC/Page+Tree+Macro
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Well, you've basically modified a confluence plugin and created your own version. So just like any other plugin you will have to "upgrade" it when you upgrade confluence. Since it's an easy change, it's probably simplest to take the latest doctheme jar and re-apply the change
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Matthew,
Thanks for the reply. If I do this, what will happen when we upgrade confluence? This change is lost?
Thanks,
Rajendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi David,
Yes, Confluence and documentation theme.
Thanks,
Rajendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do you mean Confluence & the Documentatiuon theme? More details please.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Community moderators have prevented the ability to post new answers.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.