This topic is locked

Hide Fields depending on users

11/29/2010 4:55:17 PM
ASPRunnerPro Tips and tricks
D
dara author

Hello i need your help,

i want to create a user for my phprunner website and i need this user to be able to see only some fields.

so i start writting something but i dont get it to work correctly

:


$userid = $_SESSION["UserID"];

echo $userid;

if (($userid="stanislas"));

{

$xt->assign("mobile1_fieldblock",false);

$xt->assign("nom1_fieldblock",false);

$xt->assign("prenom1_fieldblock",false);

$xt->assign("mail1_fieldblock",false);
print_r ($_SESSION["UserID"]);

}

if (($userid="olivier"));

{

$xt->assign("mobile1_fieldblock",true);

$xt->assign("nom1_fieldblock",true);

$xt->assign("prenom1_fieldblock",true);

$xt->assign("mail1_fieldblock",true);
print_r ($_SESSION["UserID"]);

}


Thanks all for your help

D
dara author 11/29/2010

ok i managed to do what i want while watching this wonderfull barcelona -real madrid 5-0!!

i was wondering if there is a way to do that without php code directly with phprunner ?

admin 11/29/2010

No, this won't be possible without PHP coding.

E
edgarv 8/1/2011



No, this won't be possible without PHP coding.



I am interested in hearing how you were able to do this, trying to do the same in ASP

A
Abhijeet 11/17/2012

Hello Team,
I want to have the same functionality but not on the basis of user name. I need to have it on the basis of user type. Can you please help me how to proceed the same code with user type ? I mean registered user, guest user, etc.
Thank you in advance.



I am interested in hearing how you were able to do this, trying to do the same in ASP