Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
WelcomeToVanillaGetSomeAddons is this an admin only thing ?
Can everyone see this or is it just the admin, was thinking of using it as an initial annoucement msg not to be confused with the annoucement extension
0
This discussion has been closed.
Comments
Here is an example of how to display a message for only those not signed in, along with an ad banner.
If you change the if statement to check for
( $Context->Session-UserID > 0 )
, then it will only show for those signed in.<?php /* Extension Name: Guest Notice Extension Url: www.lussumo.com/Add-ons/ Description: Adds a message for guests Version: 0.2 Author: WallPhone Author Url: http://wallphone.com */ if ( ($Context->Session->UserID == 0) && (in_array($Context->SelfUrl, array("index.php", "categories.php", "comments.php", "search.php", "post.php", "account.php", "settings.php"))) ){ $NoticeCollector->AddNotice('Please <a href="'.GetUrl($Configuration, 'people.php'). '">sign in</a> or <a href="'. GetUrl($Configuration, 'people.php', '', '', '', 'PostBackAction=ApplyForm'). '">apply for membership</a>.'); } ?>