Access Keys:
Skip to content (Access Key - 0)

Adaptavist Documentation Move

This documentation is deprecated. Adaptavist's documentation has moved to a new location where it is maintained and updated. Please visit Adaptavist's new Documentation area.

show-to macro


The {show-to} macro displays content only to specific users or groups...

There may be times when you want to display content on Pages, News, Comments, the Site Welcome Message and even user profiles only to particular users or groups of users and that's what the {show-to} macro is designed to do.

Such a feature allows you to, for example, personalise your site to display custom content and/or navigation depending on the logged in user.


The {show-to} macro shows it's contents based on various settings:

{show-to:user=users|group=groups|space=spaces|trim=true/false|match=all/any}Any content to be
Parameter Required Notes
user A list of one or more users to show the content to.
group A list of one or more user groups to show the content to.
space If the user has the specified privileges within the spaces listed, the content will be shown.

To add a privilege to a specific space, use "SpaceKey:Privilege". Valid privileges are:
  • view - The user can view the space (default).
  • edit - The user can edit the space.
  • admin - The user can administrate the space.
  • news - The user can add news to the space.
    Eg. space=MYSPACE,@self:edit requires MYSPACE view access or edit access to the current space (@self).
match By default, if any of the criteria match the logged in user, the content will be shown. However, if you set this parameter to all then every single criteria will have to match before the content will be shown.

This macro should only be used as a simple way to personalise content depending on the logged in user and optionally any space-specific privileges they may have.

This macro should not be used as a security mechanism. While it will only show content in specific circumstances when used normally, the content will still be indexed by the search engine and features such as Page Source will still display the content, regardless of the way you use this macro.

Do not use this macro to hide confidential or sensitive information because the content will still be visible via some views or features of the software.


Hints and Tips

When showing content to specific users or groups, etc., remember that logged out users will be not be recognised (either by user name, group or space privileges).

You could create an "advanced-users" group in order to show more advanced information to users in that group.

Frequently Asked Questions

Q Rather than showing content from specific users, etc., I want to hide it from them - how?
A Use the hide-from macro.

See Also

View old comments

Adaptavist Theme Builder Powered by Atlassian Confluence