Question

I've recently started getting familiar with Atlassian Confluence (v. 3.3), but I'm having trouble understanding the best way to use page hierarchies within a space.

Within a space, pages can be located underneath the "Home" page, or one level higher, next to the home page. However, in the "Documentation" theme, the left sidebar page hierarchy is only shown for pages rooted below "Home". This means that the "Home" breadcrumb is always displayed when viewing pages that appear in the sidebar hierarchy.

  • So, what is the purpose of having pages on this top level? Should it be used specifically to hide pages from the sidebar hierarchy (like meta)?
  • Is it possible to have the sidebar hierarchy display for pages rooted next to Home (on this top level), instead of below it?
  • Is it possible to remove the Home breadcrumb?
  • How many of these questions are made irrelevant by later updates to the software?
Was it helpful?

Solution

The only real purpose I can think of for having a page on the same level as the home page would be to disclude it from a page-tree display starting at the home page. So if you have some pages you use for holding images, documents, testing content, et cetera then you would not want it to show up in the hierarchy viewed by regular users.

When you define a page-tree macro, or the children-display or anything similar, you can specify which page it is displaying the hierarchy from. If you want to use a page other than the home page, just specify it in the page-tree macro.

I don't believe it is possible to remove the breadcrumb, or at least I don't know how.

Software updates will maybe bring some other page-tree-esque options but won't fundamentally change anything else we're talking about here.

OTHER TIPS

So, what is the purpose of having pages on this top level? Specifically? You'd have to ask Atlassian. Generally? The default configuration is that only pages from the specified Home page down are shown in the navbar.

Should it be used specifically to hide pages from the sidebar hierarchy (like meta)? Yes. Any page which is used for navigation, control or configuration is stored at the top of the hierarchy. That way they don't show up in the navbar. Using the {alias} macro will create a page in the top hierarchy. If you use a page as input to your navbar then this page can be stored here out of user sight but still publically visible. So, if you had a page with lots of markup for a colourful and exciting navbar named SpaceNavigation then in the Documentation Theme Configuration you would have this code:

{include:SpaceNavigation|nopanel=true}

Is it possible to have the sidebar hierarchy display for pages rooted next to Home (on this top level), instead of below it? Yes. Use the pagetree macro.

{pagetree:root=@none}

You can edit the space theme to show anything in the left navigation bar. Browse > Space Admin > Theme > Configure theme

Untick the 'Page Tree' option at the top. Put your code to display content in the navbar in the navigation box. If you want a pagetree somewhere in your custom navigation use the {pagetree} macro. You can set the root page to a page lower in the hierarchy. {pagetree:root=apple} The {children} macro is also useful here.

The reporting macros can print a list of all pages in a space. You can build your own macro or import a wiki page to display as the navbar.

Is it possible to remove the Home breadcrumb? This may need clarification. Are you looking to remove the breadcumbs or just the word 'home'. Either way, the answer is 'JavaScript or CSS'.

If you are a space administrator you can add CSS styles to the space to disable CSS for the space from the header. If you have the {html} macro or {style} then you can add styles and JavaScript to the wiki page. If you are a wiki administrator, or have one on your side, then you can create a macro or plugin to put CSS or JavaScript code on the page.

Here is a code sample to find two classes on a page and after the page has loaded (document.ready) hide them.

{html}

<script type="text/javascript">
AJS.$(document).ready(function() {
   AJS.$(".first").hide();
   AJS.$(".second").hide();
});

</script>

{html}

This example will remove the word 'Dashboard' as it has the class of 'first'.

Go forth and write the code to find the objects that so draw your ire and vanquish them.

CSS is also an option and sometimes less messy.

Some CSS objects can be removed from the page from within the page. E.g:

{html}
<style type="text/css">
     ol.breadcrumbs { visibility:none; !important; } 
</style>
{html}

However, to remove objects at the top of the page you need to use javascript or put CSS in the space style sheet. Browse > Space Admin > Stylesheet

How many of these questions are made irrelevant by later updates to the software? It's pretty much the same. Some styles have changed. Some things have been moved around. The general look has changed.

Some of the style sheets have changed and they have said that they are looking to deprecate the Documentation Theme. However, given the community support for the Documentation Theme even if they remove it no doubt it will be available as a downloadable theme in V6.

If you are interested in looking at this yourself then you can download Confluence V5 with a trial licence or try their OnDemand free for one month.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top