Bug and Fix: ASP.NET fails to detect IE10 causing _doPostBack is undefined JavaScript error or maintain FF5 scrollbar position
There is a bug in the browser definition files that shipped with .NET 2.0 and .NET 4, namely that they contain definitions for a certain range of browser versions. But the versions for some browsers (like IE 10) aren't within those ranges any more. Therefore, ASP.NET sees them as unknown browsers and defaults to a down-level definition, which has certain inconveniences, like that it does not support features like JavaScript.
A similar bug affects Firefox versions 5 and above
We're releasing a hotfix that will fix these, which you'll be able to get to via some KB articles. These KBs with fixes are live and are the best way to update your system. The fixes solve the browser-detection issue forever for all sites on a machine. These will be rolled up into future versions of the framework and will eventually also be on Windows Update.
.NET 4 - http://support.microsoft.com/kb/2600088
.NET 2.0 - http://support.microsoft.com/kb/2600100 for Win7 SP1/Windows Vista/Windows XP/
What the fixes do is update the ie.browser and firefox.browser files in \Windows\Microsoft.NET\Framework\<version>\Config\Browsers with new and future-proofed versions of these browser definitions. Nothing else is affected.
Summary
ASP.NET might not recognize the most current versions of some browsers, and will consequently treat them as down-level browsers. (Basically: no JavaScript.)
The fix is to get updated browser-definition files.
You can install a machine-wide fix or just fix individual projects.
Hotfixes are availble with download links.
.NET 4 - http://support.microsoft.com/kb/2600088
.NET 2.0 - http://support.microsoft.com/kb/2600100
The files will also be part of the next batch of .NET 4 fixes, which are anticipated to ship around January 2012 via Windows Update.
The next version of the .NET framework will include all the updated files.
Hotfix information
A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that described in this article. Apply this hotfix only to systems that are experiencing the problem described in this article. This hotfix might receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next software update that contains this hotfix.
Common issue that occurs without this hotfix
Consider the following scenario:
You use Windows Internet Explorer 10 to access an ASP.NET-based webpage.
The webpage starts a postback.
In this scenario, the postback fails, and you receive the following error message:
Script Error encountered", "'__doPostBack' is undefined
Note The webpage can start a postback in various ways. For example, a LinkButton control can start a postback.
ASP.NET fails to detect IE10 causing _doPostBack is undefined JavaScript error
(1 post) (1 voice)-
Posted 13 years ago #
Reply
You must log in to post.