[thelist] PHP Login from Evolt site.
Mark Groen
evolt at markgroen.com
Tue Apr 10 08:45:13 CDT 2007
On Tuesday 10 April 2007 06:13, Bowles, Mickey (RIC) wrote:
> ..........
> "I have fired up the code and love it. Anyone modified theirs for roles
> based security where you can belong to different groups/roles instead of
> just 9 for admin or 1 for user?
>
> Example, an admin would actually belong to groups 1 and 9. and a
> regular user only belongs to 1. A moderator will belong to 1, 4 and
> possibly 7, etc...
Haven't done that myself, but if no one else replies... looks like it should
be something like:
if($session->logged_in){
if(isset($_GET['userlevel'])) { $session->userlevel = $_GET['userlevel']; }
// do their thing here
} else {
// send them somewhere else or do another thing
}
--
cheers,
mark
More information about the thelist
mailing list