Top Left Text cha

Website Development Services

This is useful if you want to add a class to change things on the page depending on the usergroup.  Just insert the PHP below wherever you want to echo the usergroup...

<?php
$user = JFactory::getUser();
$groups = $user->get('groups');
foreach($groups as $group) {echo 'group'.$group.' ';}?>

Add comment


Security code
Refresh

  • No comments found

Leave your comments

Post comment as a guest

0
Your comments are subjected to administrator's moderation.
X