Redirect problem

Results 1 to 2 of 2

Thread: Redirect problem

  1. #1
    Join Date
    Dec 1969

    Default Redirect problem

    I am trying to check if a user has logged on to my site by exaiming for the presence of a cookie using the following <BR><BR> &#060;%<BR> &#039;checks for the users cookie<BR> If not Len(Request.Cookies("login")("Username"))&#062;1 Then<BR> Response.Redirect "default.asp"<BR> End If<BR> %&#062;<BR><BR>When i run the page i keep getting the error in the browser<BR><BR>Response object error &#039;ASP 0156 : 80004005&#039; <BR><BR>Header Error <BR><BR>/Spam/index.asp, line 16 <BR><BR>The HTTP headers are already written to the client browser. Any HTTP header modifications must be made before writing page content. <BR><BR>Do you know what this means and how to fix the problem?<BR>cheers<BR>Mal<BR><BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Redirect problem

    i think this is in the FAQs, but i&#039;ll answer it anyway--that should be ABOVE anything that writes something to the browser (this includes ANY javascript, asp written (response.write), or html). try doing that, you&#039;ll be ok:)

Posting Permissions

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