It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Is it possible to control what an anonymous user sees in the browse menu?

Terence McGhee Jul 29, 2011

Ideally, I'd like to be able to hide the entire browse menu from anonymous users, but if that's not possible, can I control what's shown on the browse menu to anonymous users?

6 answers

1 accepted

3 votes
Answer accepted
David Simpson Community Leader Aug 01, 2011

Browse to:

Confluence Admin | Look and Feel | Custom HTML 

In At end of the HEAD, add some javascript similar to this:

<script>
if (AJS.$('#login-link').length > 0) {
AJS.$('#browse-menu-link').parent().hide();
}
<script>
Terence McGhee Aug 07, 2011

Thank you so much David!

Terence McGhee Aug 07, 2011

This is the script I ended up using and I had to put it at the end of the body section.

<script>

if (AJS.$('#login-link').is(":visible"))

{

AJS.$('#space-pages-link').hide();

AJS.$('#space-blogposts-link').hide();

AJS.$('#space-attachments-link').hide();

AJS.$('#space-mail-link').hide();

AJS.$('#space-advanced-link').hide();

AJS.$('#whats-new-menu-link').hide();

AJS.$('#gadget-directory-link').hide();

}

</script>

David Simpson Community Leader Aug 07, 2011

Cool. That will likely do the trick :)

0 votes
David Simpson Community Leader Aug 01, 2011
0 votes
Jodie Miners Aug 31, 2011

There is also the excellent Menu Manager Plugin from CustomWare that does the trick brilliantly. https://plugins.atlassian.com/plugin/details/13460

But remember, once you have hidden the commands, the user can still access many of the Confluence features by the URL as definined in this great post http://www.divingintothedetails.com/confluence/urls-to-access-confluence-wiki-functionality/. but most of these do require the confluence pageid.

0 votes
Eric Riddle Jul 05, 2012

I was able to combine the two above answers and make it work in Confluence 4.2.

I put this script at the End of Body

<script>
if (AJS.$('#login-link').is(":visible")) {
    AJS.$('#browse-menu-link').parent().hide();
}
</script> 
0 votes
Adrian Wieczorek Feb 26, 2014

None of the above will work for OnDemand. Any other ideas?

0 votes
Stephen Thompson Mar 18, 2014

My worry is, if you run these scripts, you will lose the edit menu too and be locked out. Any plan for that scenario?

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Confluence

6 Awesome Ways to Apply Trello, JIRA and Confluence to your Project

I attended  Atlassian Summit 2019  and learned a lot from the presenters, attendees and knowledgeable Atlassian product managers. The presentations I attended focused on applying Agile, pla...

1,225 views 7 18
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you