Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/O Code)
 referring URL - login.asp
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Radianation
Junior Member

USA
186 Posts

Posted - 12 June 2003 :  17:27:56  Show Profile  Visit Radianation's Homepage  Send Radianation an ICQ Message
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  Show Profile
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 ~
Go to Top of Page

ruirib
Snitz Forums Admin

Portugal
26364 Posts

Posted - 12 June 2003 :  18:22:52  Show Profile  Send ruirib a Yahoo! Message
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
Go to Top of Page

Radianation
Junior Member

USA
186 Posts

Posted - 12 June 2003 :  19:11:04  Show Profile  Visit Radianation's Homepage  Send Radianation an ICQ Message
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.
Go to Top of Page

Radianation
Junior Member

USA
186 Posts

Posted - 12 June 2003 :  22:57:28  Show Profile  Visit Radianation's Homepage  Send Radianation an ICQ Message
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!
Go to Top of Page

ruirib
Snitz Forums Admin

Portugal
26364 Posts

Posted - 13 June 2003 :  07:26:01  Show Profile  Send ruirib a Yahoo! Message
So, just before you redirect, why not add the value of the session variable?


Snitz 3.4 Readme | Like the support? Support Snitz too
Go to Top of Page

Radianation
Junior Member

USA
186 Posts

Posted - 23 June 2003 :  02:16:19  Show Profile  Visit Radianation's Homepage  Send Radianation an ICQ Message
Well, wouldn't I need to change the code in inc_header.asp to check for session variables??
Go to Top of Page

Nikkol
Forum Moderator

USA
6907 Posts

Posted - 23 June 2003 :  06:31:50  Show Profile
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 ~
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.32 seconds. Powered By: Snitz Forums 2000 Version 3.4.07