Making ASP.NET 1.1 Work with FireFox 

As we all know browser compatibility is a major issue, trying to make you application work successfully in both IE and FireFox/Gecko based browsers, can be a very cumbersome task without making a few changes to your ASP.NET 1.1 application. ASP.NET 1.1 automatically determines if the client's browser is an up-level or a down-level browser based on information included in the <BROWSERCAPS>section of the machine.config file. The default browser caps information included with ASP.NET 1.1 and 1.0 incorrectly identifies FireFox as a down-level browser and does not render CSS, div's, Javascript and certain other important page elements.

What exactly does this mean for your page display?  The rendered page in FireFox much larger in size as it will render panels and other controls as tables instead of spans or div's, additionally CSS styles will not be applied, therefore height and width attributes will not be applied to any controls.

The good news....it is a simple fix to alter the way that ASP.NET 1.1 and 1.0 recognizes FireFox, simply add the code included in this file to your web.Config file between the opening and closing <SYSTEM.WEB>tags.

Now, I know that looks daunting, but it simply is an addition that specifies the Browser Capabilities, hence the browserCaps XML tag. For more detailed information about the browserCaps Web.Config element, please see this MSDN article http://msdn2.microsoft.com/en-us/library/x3k2ssx2.aspx

NOTE: In ASP.NET 2.0 Microsoft has modified the standard browserCaps to correctly identify FireFox and other Gecko based browsers.

Posted by Mitchel on Saturday, September 23, 2006
 

Comments

Hi Mitch,
I attended your recent talk in Wallingford, CT. Thanks for sharing!

We have a big problem with FireFox 3.5.3 often mis-displaying our DNN 4.9.2 site. We are running ASP.NET 2.0 (3.5 SP1). Just now when I entered username/password and clicked Login, I received a screenful of characters like this:

��������`I�%&/m�{J�J��t��`$ؐ@�����iG#)�*��eVe[f@�흼��{���{��;�N'���?\fdl��J�ɞ!���?~|?"~�?�7�5��:������

They display differently in FireFox, with lots of "?" within a diagonal box. This behavior never occurs in IE. Safari and Chrome work OK, though some margins are off.

In case it's relevant, this is a pre-production site with a "makecert" certificate. Another site with a Thawte cert does not do this.

Though we are beyond ASP.NET 1.1, I tried your edit to web.config, without success.

Any ideas on the problem and what we can do to solve it?

TIA, Don Stuber]

By Don Stuber on Tuesday, September 29, 2009 at 4:29 PM

Thank you... thank you... thank you...

Do you have a similar fix for Safari?

(...btw - have I said THANK YOU?)

By jose on Tuesday, February 16, 2010 at 4:08 PM

Name (required)

Email (required)

Website

CAPTCHA image
Enter the code shown above:

Content provided in this blog is provided "AS-IS" and the information should be used at your own discretion.  The thoughts and opinions expressed are the personal thoughts of Mitchel Sellers and do not reflect the opinions of his employer.

Friend of RedGate

www.datasprings.com - DotNetNuke Modules ICG Hosting

Click here for advertising information.

Content in this blog is copyright protected.  Re-publishing on other websites is allowed as long as proper credit and backlink to the article is provided.  Any other re-publishing or distribution of this content is prohibited without written permission from Mitchel Sellers.