Forums
This topic is locked
direct user from logon info
Posted 06 Feb 2003 17:08:28
1
has voted
06 Feb 2003 17:08:28 James Wilkinson posted:
When someone logs on to my site I want to direct them to one of two pages dependant on their access rights (e.g. guest/admin), how can this be done please.I went to macromedia support site www.macromedia.com/support/ultradev/ts/documents/login_otherpages.htm#auth but could not get this to work.
Any help would be most appreciated.
Edited by - slink on 06 Feb 2003 17:09:19
Replies
Replied 06 Feb 2003 19:03:51
06 Feb 2003 19:03:51 Rafi Mellado replied:
I'm not really sure the way it was meant to be done but I can tell you how I do it, and it works fine for me.
I have two types of users, and in the database one has a level of user, the other admin.
Then I have two welcome pages.
AdminWelcome.asp which only the level admin has access to, and UserWelcome.asp which both types of users have access to.
The WelcomeAdmin.asp page redirects to UserWelcome.asp in the event that someone who isn't an admin tries to access it.
The WelcomeUser.asp redirects to an Access Denied page called NotWelcome.asp
Finally my login page redirects to AdminWelcome.asp if the login is successful.
That way when a user logs in he is redirected to WelcomeAdmin.asp which then redirects him to UserWelcome.asp
It sounds more complicated than it really is, and again there might be a simpler way of doing this, but this works quite well.
Hope it helps,
DarkKave
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
When someone logs on to my site I want to direct them to one of two pages dependant on their access rights (e.g. guest/admin), how can this be done please.
I went to macromedia support site www.macromedia.com/support/ultradev/ts/documents/login_otherpages.htm#auth but could not get this to work.
Any help would be most appreciated.
Edited by - slink on 06 Feb 2003 17:09:19
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
"If it weren't for the last minute, nothing would get done."
I have two types of users, and in the database one has a level of user, the other admin.
Then I have two welcome pages.
AdminWelcome.asp which only the level admin has access to, and UserWelcome.asp which both types of users have access to.
The WelcomeAdmin.asp page redirects to UserWelcome.asp in the event that someone who isn't an admin tries to access it.
The WelcomeUser.asp redirects to an Access Denied page called NotWelcome.asp
Finally my login page redirects to AdminWelcome.asp if the login is successful.
That way when a user logs in he is redirected to WelcomeAdmin.asp which then redirects him to UserWelcome.asp
It sounds more complicated than it really is, and again there might be a simpler way of doing this, but this works quite well.
Hope it helps,
DarkKave
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
When someone logs on to my site I want to direct them to one of two pages dependant on their access rights (e.g. guest/admin), how can this be done please.
I went to macromedia support site www.macromedia.com/support/ultradev/ts/documents/login_otherpages.htm#auth but could not get this to work.
Any help would be most appreciated.
Edited by - slink on 06 Feb 2003 17:09:19
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
"If it weren't for the last minute, nothing would get done."
Replied 07 Feb 2003 10:27:53
07 Feb 2003 10:27:53 James Wilkinson replied:
Sorry, this was my fault, for some reason when setting up the site I set it up as ASPJavaScript and I use ASPVBScript - stupid I know.
It work work fine after that.
It work work fine after that.