Is the path of the page you are redirecting to coming through a query string value or is it on the form somewhere? If it isnt, Request("redirect") does you no good.
Request is used to get values out of a query string or from fields on a form (Request.QueryString and Request.Form respsectively)
Since you said that the login determines the redirect
redirect='" & UCase(redirect) & "'"
Does you no good either as you are telling the SQL Statement: "Return me all rows where the username equals this, password equals this, and redirect equals this"
In theory, if you have a column in your Users table that tells you where the user needs to go (lets call it redirect) your select statement will return a row that containst that column based on this sql statement:
"SELECT * FROM users WHERE username='"& UCase(username) & "' AND password='" & UCase(password) & "'"
So you should be able to do this:
Response.redirect(rec("redirect"))
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for:
Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html
Discussion:
http://p2p.wrox.com/topic.asp?TOPIC_ID=56429