Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Hide comments for anonymous users

Almar Hollaar April 2, 2014

Is it possible to hide the comments on a page for anonymous users and/or other groups in Confluence? Or only show comments to certain groups?

4 answers

1 vote
Fabio Racobaldo _Herzum_
Community Champion
April 2, 2014

Hi Almar,

in order to hide comments for the anonymous users you can add the following javascript to your announcement banner in JIRA

<script>
jQuery().ready(function() {
if(jQuery(".login-link").size()>0){
 jQuery("#comment-tabpanel").hide();
}
});
</script>

Pieterjan Vanpee August 10, 2016

Hello Fabio,

 

will this hide all comments for all projects for anonymous users? How would it be possible to hide comments for some particular projects?

Thanks for your help!

Fabio Racobaldo _Herzum_
Community Champion
August 11, 2016

Hello,

yes, it will hide comments for all projects. In order to hide comments just for specific projects you shoud add a check based on the URL (it contains project key).

<script>
jQuery().ready(function() {
var url = window.location.href;
if(jQuery(".login-link").size()>0 && url.includes("YOUR_PROJECT_KEY_HERE")){
 jQuery("#comment-tabpanel").hide(); 
}
});
</script>

Hope it helps,

Fabio

Ivan Dimitrijevic
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 21, 2018

Hi,

 

Unfortunately this does not stop users on a mobile web browser to see comments :(

 

Any workaround?

0 votes
YouriDS March 15, 2016

Talk addon provides permissions for public spaces:

https://docs.stiltsoft.com/display/public/Talk/Managing+Permissions#ManagingPermissions-4

You could have private comments for your team.

0 votes
Peter Van de Voorde
Community Champion
April 2, 2014

Almar,

You can set security on comments : https://confluence.atlassian.com/display/JIRA/Commenting+on+an+Issue

In the Add comment part you can read how to set security on a comment.

Best regards,

Peter

Almar Hollaar April 2, 2014

Yes in JIRA, but not in Confluence

Peter Van de Voorde
Community Champion
April 2, 2014

Oops, my mistake, I'll delete this answer.

0 votes
Christian Koch
Contributor
April 2, 2014

Adding comments is a permission but every page viewer is allowed to view the comments, too. You have two possibilties. Change the velocity code in your theme or develop a plugin.

Almar Hollaar April 2, 2014

I was afraid of that :-(

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, loom, loom for training, loom for teaching, video training, async learning, online education, screen recording, loom tutorials, loom use cases, atlassian learning, team training tools, instructional video, virtual training tools

🛗 Elevate Your Training and Enablement with Loom

Join us June 26, 11am PT for a webinar with Atlassian Champion Robert Hean & Loom’s Brittany Soinski. Hear tips, stories, and get your burning questions answered. Learn how Loom makes training and enablement easier. Don’t miss it!

Register today
AUG Leaders

Atlassian Community Events