Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. response.redirect gives -400 error.

response.redirect gives -400 error.

Scheduled Pinned Locked Moved ASP.NET
csharpvisual-studiohelpquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    vjvjvjvj
    wrote on last edited by
    #1

    Hi, My website shows a sessiontimeout page when some event happens on a page and the the sesssion is expired. All Page inherits from sessionmanagement class In the init function of sessionmanagement class, in case the session is expired, it redirects page to sessiontimeout.htm which is in the same folder as response.redirect("sessiontimeout.htm") For main.aspx it works fine, shows sessiontimeout.htm fine. main.aspx has ajaxtabcontainer and each tab has iframe. The pages in the iframe are also inherited from sessionmanagement class. In case session expires and any event happens in the pages in the iframe, it tries to load sessiontimeout.htm but gives error -400. I checked the properties in browser. To my surprise, it was trying to load as //sessiontimeout.htm e.g. if my baseurl is http://myserver/mysite it was trying to load as http://myserver/mysite/mysite/sessiontimeout.htm I dont know why it was appending the base root folder again. Why it is giving this strange behaviour from pages in iframe when all the pages are in the same folder? I guess for this application, this was not happening in visual studio 2008 but now I am using visual studio 2010. Any suggestions? Thanks Vijay

    S 1 Reply Last reply
    0
    • V vjvjvjvj

      Hi, My website shows a sessiontimeout page when some event happens on a page and the the sesssion is expired. All Page inherits from sessionmanagement class In the init function of sessionmanagement class, in case the session is expired, it redirects page to sessiontimeout.htm which is in the same folder as response.redirect("sessiontimeout.htm") For main.aspx it works fine, shows sessiontimeout.htm fine. main.aspx has ajaxtabcontainer and each tab has iframe. The pages in the iframe are also inherited from sessionmanagement class. In case session expires and any event happens in the pages in the iframe, it tries to load sessiontimeout.htm but gives error -400. I checked the properties in browser. To my surprise, it was trying to load as //sessiontimeout.htm e.g. if my baseurl is http://myserver/mysite it was trying to load as http://myserver/mysite/mysite/sessiontimeout.htm I dont know why it was appending the base root folder again. Why it is giving this strange behaviour from pages in iframe when all the pages are in the same folder? I guess for this application, this was not happening in visual studio 2008 but now I am using visual studio 2010. Any suggestions? Thanks Vijay

      S Offline
      S Offline
      Sandeep Mewara
      wrote on last edited by
      #2

      Please dont post the same question to multiple forums. Pick one and stick to it. Other quetion posted here: http://www.codeproject.com/Questions/90278/response-redirect-gives-error-400-error.aspx[^]

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups