Response.Redirect-2 problems

Results 1 to 4 of 4

Thread: Response.Redirect-2 problems

  1. #1
    Bill Logan Guest

    Default Response.Redirect-2 problems

    Hi<BR>I want to redirect from one asp page (that needs no HTML content) to another asp page.<BR>There are two problems with this<BR>1.Response.Redirect cannot be called after header info is received by client browser.<BR><BR>So I placed the code at the top of the page, giving me problem <BR><BR>2.%&#062; required at end of script block. It has one. I checked several times<BR><BR>Can anyone tell me why error 2 occurs or where exactly at the top of the page it should go?

  2. #2
    Ian Stallings Guest

    Default RE: Response.Redirect-2 problems

    Make sure you have &#060;% Response.Buffer = True %&#062; at the very<BR>top of the asp. Using this, the asp is parsed/processed<BR> before any headers are sent. Since a redirect is basically<BR>a header stating that the page is at a different location<BR>this is necessary.<BR><BR>hope this helps.

  3. #3
    Bill Logan Guest

    Default RE: Response.Redirect-2 problems

    Thanks for the tip Ian. I have tried placing Response.Buffer = True at the very top of the asp page but the &#060;%@ Language=VBScript%&#062; becomes an error if it is not the first thing on the page. <BR>Placing the &#060;%Response.Buffer = True%&#062; immediately afterwards gives the "missing closing %&#062; on script block" error. <BR>Placing the Response.Buffer = True in the same script block tag as the @ command also gives an error.<BR>Maybe someoene can see which (undoubtedly trivial) mistake I&#039m making for this to happen.<BR>Thanks<BR>Bill Logan

  4. #4
    Sung Bae Guest

    Default RE: Response.Redirect-2 problems

    count your "&#060;%" and your "&&#062;" your probably have at least one more of the former than the latter


Posting Permissions

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