Another one for you guys (set sessions based on results)
Posted: Mon Sep 18, 2006 4:12 pm
Hi Guys,
I have another little issue here.
I am selecting some fields from the database like this
I now need to get each results module name and level and store them in a seperate session variable like this
Can anyone please point me in the right direction?
Thanks
I have another little issue here.
I am selecting some fields from the database like this
Code: Select all
include_once("connect.php");
$myuserid = $_SESSION['myuserid'];
$getnav = "SELECT userid, module, level FROM security WHERE userid='$userid'";
$getnavresult = mysql_query($getnav) or die($getnav);
while ($row = mysql_fetch_array($getnavresult))
extract($row);Code: Select all
$_SESSION['module1'] = $row1 etc
$_SESSION['module1level'] = $row1 etcThanks