I already have code to tell if a user is signed in. Is there a way to tell if the user is an admin?
globalize $context and then use $context['user']['is_admin']
That won't always work depending on where the code in question is - if it's in SSI or using the API, that won't work...
So what code is being used?