Skip to end of metadata
Go to start of metadata

I am creating an Intranet that contains multiple spaces. Each department is its own space, and the menu bar navigation that runs thru the entire site links to each of these spaces. I use relative linking, because I have Test and Production servers that I push the changes thru. This is a snippet of the code I use:

{menu}Departments
{menuitem}{menulink:custom|link=./display/CORP/Administration}Administration{menulink}{menuitem}
{menuitem}{menulink:custom|link=./display/CORP/HR}Human Resources{menulink}{menuitem}
{menuitem}{menulink:custom|link=./display/IT/Information+Technology}Information Technology{menulink}{menuitem}
{menuitem}{menulink:custom|link=./display/MKTG/Marketing}Marketing{menulink}{menuitem}
{menu}

This works perfectly in all spaces, until I go to the Space Admin pages or try to Edit/Add a page. This is because the link structure changes from /display/SpaceName/pageName to just /pages/pageName. So when it hits this link, it moves back an extra directory and breaks the link.

It seems like there should be a simple solution for this, but I've tried several things and cannot make it work. I am open to any suggestions!

I am using Theme Builder 3.3.3, Confluence 2.10, and I greatly appreciate your help!

  • No labels

8 Comments

  1. The short answer is 'dont do that it wont work!'

    You would be much better off with using either the Menulink Aliases Tab or use a 'normalView' menulink and set the page/space.

    1. Unknown User (jamie.zabel)

      That's what I was afraid of - thanks Alain!
      If I use the Menulink Aliases, when transferring them to my Production server, are they included in the Themes when I export them to a file, or will I have to create these from scratch in Production?

      1. Menulink aliases may be backed up and installed onto your production server using the layout backup/restore utilities in the Backup Tab in Theme Administration

        1. Unknown User (jamie.zabel)

          I get an "Unknown Runtime Error" message box when I try to save a link alias.  I've tried several different spaces and alias names, but get the same error message box.

          I have chosen the radio button next to URL, entered the URL PWCorp:Claims, the Alias claimsBio, and left Rel blank (not sure what it's for?).

          Any thoughts - I have a printscreen, but the forum isn't letting me upload it to this post.

          Thanks again for your help!

          1. That's a known issue with IE, this 'should' be resolved by 3.4.0-M1 which ditches the problematic Ext library used for the builder admin interface.

            1. Unknown User (jamie.zabel)

              Because I'm linking to a page inside Confluence, I added the URL PWCorp:Claims and the Alias claimsBio using FireFox (smile)
              Then I added the menulink:

              {menuitem}{menulink:claimsBio}Claims{menulink}{menuitem}

              When I use the link, it clears the address bar and just puts pwcorp:claims in the address bar and doesn't forward to the space. Do you know what I am missing?

  2. Unknown User (gfraser)

    Instead of this:

    {menuitem}{menulink:custom|link=./display/IT/Information+Technology}Information Technology{menulink}{menuitem}
    

    Use this (from memory - check the "wikiPage" is a valid location in the docs):

     {compound-menuitem:wikiPage|space=IT|page=Information Technology}
    

    That should work - I assume you've set the correct base URL on your staging/test instance?

    1. Unknown User (jamie.zabel)

      Yes, that solves my problem! Thanks so much, Guy!