The current project I am working on involves a website that is external facing. Since I am using CSS and JavaScript in ASP.NET 2.0 older browsers may not behave as expected. Therefore, I implemented White, Black, and Gray browser lists.
Initially, I used a JavaScript Browser Sniffer Library written by Pau Garcia i Quiles, but then I became aware of the HttpBrowserCompatibilites class in .NET!
I just finished rewritting the lists using .NET's Browser object ( located off the Request object ). If you are interested in knowing how .NET figures out all this information check out the Browser Definition File Schema. You can find all of the browser definitions on your machine at "%SystemRoot%\Microsoft.NET\Framework\version\CONFIG\Browsers". Its very interesting to look through the files and see what information .NET uses to determine your browser information.
No comments:
Post a Comment