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.
The following 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.
If you don't want to install those hotfixes on a production system, then you can create an App_Browsers folder under your website root directory and put the following browser config files on it.
The following 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 Server 2008 R2 SP1, Windows Vista/Server 2008, Windows XP/Server 2003
- http://support.microsoft.com/kb/2608565 for Win7/Windows Server 2008 R2 RTM
If you don't want to install those hotfixes on a production system, then you can create an App_Browsers folder under your website root directory and put the following browser config files on it.
- You can also update your entire machine's browser files.
- Copy the files from the .\machines folder into \Windows\Microsoft.NET\Framework\v4.0.30319\Config\Browsers, overwriting your previous versions
- Open a command prompt and run \Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_regbrowsers.exe -i
- Restart IIS (e.g., with iisreset)
Commentaires