Documentation

is_admin


is_admin

Return if the user is admin or super admin. You can pass the $user_id to select a user from database.

if( User::is_admin() )
     echo "Hello admin";