Currently I am working on a custom component.
In the front-end I would like to restrict some options to editors or above.
My idea to accomplish this is to use the GID of the user (should be between 20 and 25).
I tried
Code: Select all
global $my;
echo $my->gid;
The admin user has GID 25, but when I am logged in with 'admin' the above prints '2'.
What am I doing wrong?