ASP - Form redirect to same page - BACK button does not work ???

Discussion in 'ASP General' started by Hugo Botha, Jul 11, 2004.

  1. Hugo Botha

    Hugo Botha Guest

    Hi,

    I have created 2 asp pages called testa.asp and testb.asp

    testa.asp has a link to go to next page testb.asp

    testb.asp has a form that ask you for a reference number and post it
    to the same page testb.asp

    If the reference number is not blank, it will just write out what the
    reference number is.

    Now my problem....

    If you go to testa.asp and click on the link to go to testb.asp you
    will see the form. At this point, if you click the back button, it
    till take you back to testa.asp ALL FINE SO FAR.

    If you go to testb.asp again and see the form, enter a number say 33
    and click on search. This will now show you the number you have just
    entered. NOW - click on the BACK BUTTON, it will just show you exactly
    the same page ! WHY does it not go back to the FORM in order to refill
    in a different number.

    You can see this example on :
    http://www.oliproperties.com/oliproperties/testa.asp

    Here is the code for testa.asp
    <%
    Response.Expires = -2000 'Makes the browser not cache this page

    %>
    <a href="testb.asp">click</a>

    Here is the code for testb.asp
    <%
    Response.Expires = -2000 'Makes the browser not cache this page
    Reference_No = Request.Form("Reference_No")

    If Reference_No = "" Then

    %>

    <form name=form1 action=testb.asp method=post>

    <TABLE cellSpacing=0 cellPadding=5>
    <TBODY>
    <TR>
    <TD align="center" class=txt><B>Reference Number
    :</B><BR>
    <input type=text name=Reference_No size="25" value=""
    TabIndex=1><BR>
    <input type=hidden name=login value=true>
    <input type=submit value="Search"></TD>
    </TR>
    </TBODY>
    </TABLE>

    </form>

    <%
    Else
    response.write " reference number = " & Reference_No
    End If
    %>

    Can anyone help please ????

    e-mail

    Thank you very much

    Hugo
     
    Hugo Botha, Jul 11, 2004
    #1
    1. Advertising

  2. Hugo Botha

    Maarten Guest

    <form name=form1 action=testb.asp method=post target="_blank">
     
    Maarten, Jul 11, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?VHJveQ==?=

    Response.redirect does not redirect from .aspx page

    =?Utf-8?B?VHJveQ==?=, Oct 18, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    5,261
    Srowe1975
    Oct 15, 2008
  2. sylvia sil
    Replies:
    1
    Views:
    621
    Curt_C [MVP]
    Dec 29, 2004
  3. phancey
    Replies:
    3
    Views:
    2,587
  4. Jiong Feng
    Replies:
    9
    Views:
    1,377
    Lasse Reichstein Nielsen
    Jun 24, 2004
  5. DBLWizard
    Replies:
    1
    Views:
    93
    DBLWizard
    May 5, 2005
Loading...

Share This Page