Alternative Content By Group (2)

Below you can see the code used to provide alternative content on this page, so that registered users that are assigned to group2 see the message "You have access" and all others will see "You DO NOT have access".

What the user sees

Message:
You DO NOT have access.
 

The code used

<?php if ($userSessionPro->hasGroupAccess('group2')){ ?>
<div class="demoMessage">Message:<br />You have access.</div>
<?php }else{ ?>
<div class="demoMessage">Message:<br />You DO NOT have access.</div>
<?php } ?>
 

Still have questions about User Session Pro?

Do you have any queries, comments or suggestions you would like us to address?
(If you would like us to get back to you please include your email address.)
Subject:
 
 
ProPHPScripts