user1511953
user1511953

Reputation: 43

Role of ie.browser file in .net framework

i need to know the role of ie.browser file which is there in .net framework which stores the definition of browser version under following folder WINDOWS\Microsoft.NET\Framework\v4.0.30319\Config\Browsers.

i need to know how framework uses it and how it effects the rendering of web page.

i wanted to add something that this file is only observed in framework 2.0 and 4.0, why this has been skipped in earlier version.

need to know details.

What if the definition for certain browser is missing does it generate HTML according to previous version or does it in different way? for eg: definition for IE 10 is missing from browser files but still it displays webpage, however some code does not works as expected.

can any one explain why such behavior is there?

Upvotes: 1

Views: 2473

Answers (2)

David Cummins
David Cummins

Reputation: 988

Broadly speaking ASP.NET 2.0+ classifies browsers as having advanced or basic capabilities, particularly with respect to Javascript. Depending upon how a browser is classified, different HTML is emitted for server-side controls. A little ironically, Microsoft originally classified IE as the only advanced browser. Users using other browsers got a second-class experience. I believe this feature was only added in 2.0, therefore was not present in earlier versions.

Upvotes: 0

CodeCaster
CodeCaster

Reputation: 151594

Read this and this: explain what you are trying to do, not what you think your solution is. Messing with framework files usually is not the way to go. Anyway the documentation says:

Browser definition files contain definitions for individual browsers. At run time, ASP.NET uses the information in the request header to determine what type of browser has made the request. Then ASP.NET uses .browser files to determine the capabilities of the browser. ASP.NET control adapters can use this information to adapt the behavior of an ASP.NET Web server control depending on the type of device. For example, a server control might generate different HTML for a graphical browser such as Internet Explorer than it would for a mobile device.

Upvotes: 3

Related Questions