Today I was working with a customer on an interesting issue. The issue was with his website giving him "Page cannot be displayed" while browsing on IE, but working well with Firefox. I work in the IIS ASP support team here in Microsoft. In the beginning, I was sure that the issue to be with the Internet Explorer, but not sure what was the real cause for the problem.

It was a shopping application and this problem occurred while adding the items to the shopping cart. We took Fiddler trace. We found that the application is redirecting to an URL which had a very long query string. The total length of the URL was 3733. Yeah you read it right!

Internet Explorer has a restriction of the length of the URL being browsed due to some security reasons. http://support.microsoft.com/kb/208427 has more information on this *fact*. You can request for an URL of maximum length 2048. Another interesting fact is IE doesn't allow the user to type more than 2048 characters in the address bar. Cool deal ha! But, you may ask now how was the length of the URL was 3733 on this case. It was a redirection made inside the application.

For example, you can try the following code in your index.asp:

   1: <%
   2:   Request.Redirect "http://localhost/index.asp?ID=31844067,31844069,31844071,31844073,31844075,31844077,31844079,31844080,31844082,31844084,31844086,31844088,31844090,31844092,31844094,31844096,31844098,31844099,31844101,31844103,31844106,31844107,31844109,31844111,31844113,31844115,31844117,31844119,31844121,31844123,31844125,31844127,31844129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,3184q31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,3184q31844135,31844137,31844139,31844141,31844143,31844145,31844147,3184414944129,31844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q1844131,31844133,3184q31844147,3184414944129,31844131,31844133,3184q"
   3: %>

I advise you not to try this on a *production-server*. And you may ask now, why it was working with Firefox. I am not really sure on this, guess Firefox doesn't have any limit to the URL length.