Forum Discussion

srujanayeruvaka's avatar
8 years ago

How to hide 'Share' button for Anonymous users?

Hi,   Is there a way to hide the 'Share' button from posts/blogs/etc, for Anonymous users? Looking for a way to hide the below component by default for unregistered users. <component id="external....
  • ChiaraS's avatar
    ChiaraS
    8 years ago

    srujanayeruvaka

     

    you can create a custom component named external.widget.add-this@override

     

    and add the following code in it:

    <#if user.registered>
    <@delegate/>
    </#if>

    That should only render the component for logged-in users.