Passing values forward with Response.Redirect

Results 1 to 2 of 2

Thread: Passing values forward with Response.Redirect

  1. #1
    Crew Guest

    Default Passing values forward with Response.Redirect

    *<BR>Scenario<BR><BR>There is a List of Eligible Users in a database table called EligibleUsers<BR>These people are eligible for access to a site<BR><BR>There is a registration form where eligible users can enter their information to request access.<BR><BR>Three of the criteria entered into the form is matched to criteria in EligibleUsers (criteria such as passport number, membership number, date of access)<BR><BR>If the three criteria match, the member&#039;s information is written to a Members table including name, login and password.<BR><BR>Function<BR><BR>I have a registration page where the info is captured<BR><BR>I have a Verification page where:<BR>1) The 3 criteria is retrieved from Eligible Users<BR>2) The 3 criteria is requested from the Form on the previous page<BR>3) The three criteria is compared e.g. If EligiblePassportNumber = RegisterPassportNumber Then Counter = Counter + 1<BR>4) If Counter &#062;2 Then ... and here is the trouble<BR><BR>I want to do a Response.Redirect to the VerifySave page which will save the info to the Members table<BR>But I need to pass all the other information (such as name, login, password) to the VerifySave page too.<BR>I can request it from the form on the Register page but how do I pass it to the Verify Save page if I use a Response.Redirect ? Usually I pass info over by using hidden fields of a form but there is obviously no Submit in a Response.Redirect. <BR>Is Reponse.Redirect the best (or only) way to automatically run another page? And is it right for this purpose?

  2. #2
    Join Date
    Dec 1969

    Default RE: Passing values forward with Response.Redirect

    Querystrings are the perfect way to pass anything accross however the only problem is the users can see them at the top in the address bar.<BR><BR>So you could put <BR><BR>VerifySave.asp?name=&#060;%=request.form(" name")%&#062;&login&#060;%=request.form("login")%& #062;&pass=&#060;%=request.form("password")%&#062; <BR><BR>this would then pass the next page the 3 pieces of info you need passed.<BR><BR>To get them the other side the statements would be<BR><BR>login = request.querystring("login") etc.<BR><BR>if you use the &#039;form action = "get"&#039; rather than "post" it will convert all your fields into a querystring anyway.<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts