Check usergroup to insert code

Moderators: mandville, General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
JohnWi
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 176
Joined: Mon Jan 30, 2012 11:02 am

Check usergroup to insert code

Post by JohnWi » Thu Jul 30, 2015 5:26 pm

Hi.

I have two usergroups in my website, and I need to insert different code in the template depending on the which of them had logged in.

I am working with Joomla! 3.4.2.

Many thanks friends.

jcms
I've been banned!
Posts: 2233
Joined: Wed Nov 19, 2014 9:23 am

Re: Check usergroup to insert code

Post by jcms » Fri Jul 31, 2015 7:03 am

$user = JFactory::getUser();
after login, check the user group, type then you can insert code.


Locked

Return to “Access Control List (ACL) in Joomla! 3.x”