Anyone able to suppress the Child Pages/Page Tree section in the sidebar using the CSS or Javascript in this article?

Saw this article https://confluence.atlassian.com/confkb/how-to-hide-elements-in-confluence-using-css-or-javascript-313458894.html

We're using Confluence 5.9.  None of the items in the article seem to affect the sidebar content.  We are using the Spacetree macro to display pages instead, and the workspaces were originally created with the Documentation theme, which did not display the Child Pages/Page Tree section in the sidebar.    Now, we want to change to the default theme so we can use the JIRA links button feature in the workspaces.  But now the Child Pages display in the sidebar, below the Spacetree listing, and clutter up the section.

1 answer

1 accepted

0 votes
Accepted answer

I removed nearly all content by adding the following Space Stylesheet

# change layout of in out block
.bvPB_panelContent {
  border-style:solid;
  font-size:20px;
  text-align:center;
}
.confluenceTh, .confluenceTd {
  border:1 solid lightgrey;
  padding:5px 5px;
  text-align:center;
font-weight: bold;
}
# remove statusline on top
#header .aui-header {
  background-color:#FFFFFF;
  color:#292929;
  display:none;
}

#remove header and other stuff
body.theme-documentation #header .aui-header {
  display:none;
}
#title-heading.with-breadcrumbs img {
  display:none;
}
.page-metadata ul li {
  display:none;
}
body.theme-documentation #header .aui-header {
  display:none;
}
element.style {
  display:none;
}
#pagetreesearch form input.text {
  display:none;
}
#pagetreesearch form input.aui-button {
  display:none;
}
#comments-actions.aui-toolbar {
  display:none;
}
#comments-section .quick-comment-container.add {
   display:none;
}
body.theme-documentation #footer .footer-body {
 
  display:none;
 
}

But be aware - to edit the layout later you have to know the link to change the space layout

 

www.something.com/spaces/choosetheme.action?key=SPACESHORTNAME&src=spacetools

 

perhaps it helps

I copy/pasted this into the Stylesheet, and saw some item disappear in the actual page (the "Created by" and "last modified" info, and the "Write a comment..." box), but the sidebar remains the same.  I'm not an HTML expert, but it seems these types of functions don't work for items in the sidebar.

ok - you are right - when I remember right, there was a difference between several browsers, removing the sidebar once using chrome fixed the problem permanent, IE never worked. I´ll give it a try this weekend, perhaps I can find a solution.

 

best Robert

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Organizing your space just got easier - Page Tree Drag & Drop is here

Hi Community! I’m Elaine, Confluence Product Manager. You may have read my earlier post about page tree in space navigation sidebar. I'm excited to share another improvement that helps you organize ...

118 views 3 4
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you