Solution to undefined ASP. NET pagerequestmanager and _ dopostback in ie10

Source: Internet
Author: User
Tags visual studio 2010

This includes ff5
About ASP. NET
4 and
ASP. NET 2.0
Ie10 and
Ie10 Browser file.

You can update your entire machine's Browser file.

1. copy the file from. Copy the \ machines folder to \ windows \ Microsoft. net \ framework \ v4.0.30319 \ config \ browsers, overwrite Previous Version 2. open the upgraded command prompt and run \ windows \ Microsoft. net \ framework \ v4.0.30319 \ aspnet_regbrowsers.exe-i3. restart IIS
(For example, with iisreset)

Please note the file. This zip
File \ Projects
Folder, from those in different.
\ Machines folder. To update a single project, the file will be copied.
\ Projects
ZIP file to your project ~ \ App_browsers
Folder.

However, the easiest way to update a single project is to use nuget.

. Net4ps> install-Package
App_browsersupdate

For. net2.0
(Use nuget.exe
Command line.

Note: nuget.exe
Use. net4, so if your computer only has. net2, You need to manually copy the file.

PS> install-Package
App_browsersupdate.net20

Browser version numbers continue to march on. ie9 is here, ie10 is coming, Firefox 5 and
6 are here with 7 and 8 in the wings, opera's on 11, and chrome is on, I dunno, somewhere between 14 and 50. regardless, we'll all be on version 99 before the singularity.

There isA bug in the browser definition filesThat shipped. 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.

If you want to see this for yourself, create a new, blank web site (e.g. in Visual Studio 2010), add a control that requires JavaScript For PostBack (good example: <asp: linkbutton>), and then run the site using ie9 (where it works) and ie10 (where it won't ).
View the page source and compare the HTML and JavaScript sent to each Browser
.

A similar bug affects Firefox versions 5 and above, where support for using JavaScript to reposition the scrollbar in the browser is not detected. This basically breaks the maintainscrollbackpositiononpostback property for web forms pages.

These "misdetection" Bugs affect web forms pages in both ASP. net 2 and ASP. net 4. if you are using ASP. net web pages, or if you're using ASP. net MVC or ASP. net web pages and are not using the browser object to detect JavaScript support, you will not be affected.

Fixes

There are two ways to fix this: one is a machine-wide fix, the other is a way to fix individual sites.

Machine-wide fixes

We're 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 ure 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

What the fixes do is updateIe. BrowserAndFirefox. BrowserFiles in\ Windows \ microsoft. Net \ framework \ <version> \ config \ browsers With new and future-proofed versions of these browser definitions. Nothing else is
Affected.

Site-only fixes

If
You don't have access to the whole machine and/or just want to update a single project, use nuget to installApp_browsersupdatePackage. Your SITE STRUCTURE IN SOLUTION
Explorer will then look like the image at right. Note that nuget uses. Net 4, so for systems that haveOnly. Net 2, you'll need to get
ZIP file and put the new browser files in app_browsers manually.

  • . Net 4 browser update nuget package-http://nuget.org/List/Packages/App_browsersupdate

    • Install-package app_browsersupdate
  • . NET 2.0 Browser update nuget package-http://nuget.org/List/Packages/App_browsersupdate.net20

    • Install-package app_browsersupdate.net20
    • Note that nuget is vs2010 specific so if you don't have nuget.exe and. Net 4, you can also copy the. NET 2 updated browser files ~ \ App_browsers manually
      From this ZIP file.

Updating the whole machine is the preferred way to fix this.

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.

If you're interested in more detail than you need, I 've uploadedUpdated versions of Firefox. browser and IE. BrowserFiles
That are expected to ship with the next version of ASP. NET. The files and source is up at my Bitbucket repo if you are interested in the details.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.