|
| |
|
|
Mav44
Posts: 197 Joined: 6/25/2006 Status: offline
|
Login and Set user level for page - 10/11/2009 12:55:51
I would like to be able to include something like the following on my pages that would set the user level for calling up data later in the page after login. <% If Session("admin3") <> true Then Response.Redirect("login.asp?requester=main.asp") end if If session = ("admin3") than user = Session("admin3") elseif session = ("shopper3") than user = Session("shopper3") end If %> then later beable to call back up this user level for infoamtion returned <% user = request.form("user") then sql = "select * from db23 where ulevel = ' & user & ' " where shopitems = 'new' I know this is no where near right but I am hoping you guys can set my on the right track.
|
|
|
|
Mav44
Posts: 197 Joined: 6/25/2006 Status: offline
|
RE: Login and Set user level for page - 10/12/2009 0:07:03
Maybe skip the top segment and just qualify in the bottom statement like: If session ("admin3") <> true then set name="user" id="user" value="admin" End If then sql = "select * from db23 where ulevel = ' & user & ' and where shopitems = 'new'
|
|
|
|
ou812
Posts: 1705 Joined: 1/5/2002 From: San Diego Status: offline
|
RE: Login and Set user level for page - 10/12/2009 13:13:27
I'm not sure what you're trying to do. Sorry. Are user levels static and can't they be set in the DB. Then, when they login grab the user level at that time? Then, on pages display or do whatever is needed depending on their user level?
_____________________________
-brian Black Holes suck. EnterpriseDB: Enterprise-class relational database management system PostgreSQL: The world's most advanced open source database
|
|
|
|
Mav44
Posts: 197 Joined: 6/25/2006 Status: offline
|
RE: Login and Set user level for page - 10/12/2009 13:20:34
Yes each line has a "user level" assigned to it. I am trying to use the session name to specify that only these lines are called up. I just need to figure out how to use the session name in an "if" statement to set the criteria for the results.
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|