Size Constraint on Location Header of Http Response

C

chandra.somesh

I generally use Response.Redirect(url,false) for redirections.

Is there a size constarint on the HTTP Response Location Header ?

Also Is the behavior defined if we exceed this limit?

In my web app there are cases where the url being passed to the
redirection method is very long.What should be the expected behavior in
such cases? In my case this results in no redirection.
 
G

Guest

I dont think there is a limit in the protocol definition but I know IE has a
maximum URL length, i cant remember the exact value but it is pretty long.
You should look for a way to shorten the URL. also, in the repsonse, try
sending down a meta tag to move the browser, and/or some javascript to set
the window.location. You'll need to write a custom redirect function for this
but it might be worth it. Just clear the buffer, set the status to 304, set
the location header and spit out the html for the meta and javascript, then
close response.flush() and response.close()

HTH

Ciaran O'Donnell
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top