Author |
Topic |
|
Radianation
Junior Member
USA
186 Posts |
Posted - 12 June 2003 : 17:27:56
|
At the bottom of inc_header.asp I added: session("mLev") = mLev
Now I have a small include file with a check on whether mLev = 0. I am including this file on certain pages on my website that I want users to be logged in to check. If they are not logged in, it sends them to login.asp ... After they login I want it to bounce them back to the page. What is the variable snitz uses to keep track of the page the user was last seen on so that it can redirect them back there after logging in (instead of to default.asp).
- Rad!
|
Edited by - ruirib on 12 June 2003 18:21:41 |
|
Nikkol
Forum Moderator
USA
6907 Posts |
Posted - 12 June 2003 : 17:46:49
|
redirection in snitz on somepages is handled by using a querystring value called target. Look at some of the admin pages and you'll see it in use there. |
Nikkol ~ Help Us Help You | ReadMe | 3.4.03 fixes | security fixes ~ |
|
|
ruirib
Snitz Forums Admin
Portugal
26364 Posts |
Posted - 12 June 2003 : 18:22:52
|
Since you know the page the user wanted to access, you can also store it in a session var, since you seem to like using session vars, and then redirect to the page stored in the session var. |
Snitz 3.4 Readme | Like the support? Support Snitz too |
|
|
Radianation
Junior Member
USA
186 Posts |
Posted - 12 June 2003 : 19:11:04
|
Yes, I do prefer session variables for some things, but I don't mind passing a querstring value. I'll have a crack at it. |
|
|
Radianation
Junior Member
USA
186 Posts |
Posted - 12 June 2003 : 22:57:28
|
Ok, here is my problem now. It will pass the referring URL, and the login page sends them back to the correct page, but the correct page is not getting the session variable I added in inc_header.asp correct until they go through this loop twice. I can't simply include the inc_header.asp because I have custom edited it and it can only be used on the forum (plus it has the forum links and I don't want them listed). I guess I don't mind simply checking if they have a cookie for my website and if so let them login. I don't even really need to check for the password. However, my request.cookies("user") string doesn't seem to be returning anything. Heeeelp =)
- Rad! |
|
|
ruirib
Snitz Forums Admin
Portugal
26364 Posts |
|
Radianation
Junior Member
USA
186 Posts |
Posted - 23 June 2003 : 02:16:19
|
Well, wouldn't I need to change the code in inc_header.asp to check for session variables?? |
|
|
Nikkol
Forum Moderator
USA
6907 Posts |
Posted - 23 June 2003 : 06:31:50
|
When updating session variables you need to do it twice, so...
some code
Session("blahblahblah")="blah" Session("blahblahblah")="blah"
more code |
Nikkol ~ Help Us Help You | ReadMe | 3.4.03 fixes | security fixes ~ |
|
|
|
Topic |
|