Adaptive Rendering Issue

  • Thread starter Thread starter Nacho Nachev
  • Start date Start date
N

Nacho Nachev

Hello,

AFIAK ASP.NET (1.1) uses a technology called 'Adpative Rendering' to output
HTML that is compliant with the client browser or at least stick to HTML 4
specification or IE.

This seems to be quite a problem for me. I have HTML output for Mozilla that
has missing style attribute in list boxes and buttons and my layout seems
crappy. If I save the HTML that comes for IE and open the file with Mozilla
everything seems correct.

So it's seems that If I disable the Adaptive Rendering feature and make it
render as compliant with IE it will work fine for my page. How can I do
this?

Still I don't consider this way to be correct. Can I workaround this
completely if I use CSS class?

Thanks for your time,
Nacho
 
You would need to provide sample code that shows an example of this
happening. I seldom experience any problems with this because I do
several things.
#1 - I specify a FULL DTD at the top of each web browser page forcing
IE to not operate in "quirks mode". This means that its rendering will
be more compliant with other compliant browsers.
#2 - Try avoiding using certain controls. From my experience the
controls that most notably change the most under alternate browsers are
the asp:Panel, asp:Label. In cases like this you should use <label,
<div or <span respectively and jsut add a runat="server" attribute to
them.
#3 - I try specfing as many attributes as possible through CSS classes
or through the .Style property programmatically.

If neither of the above tips helps and youa re still experiencing
problems you should post sample output from both browsers and related
code and markup.
 
in machine.config you will find a <browserCaps> section, you can update this
to improve the rendering. or looking at the agent string force uplevel
support yourself.

if ("netscape|gecko|opera".IndexO­f
(this.Request.Browser.Browser.­ToLower()) >= 0 )
this.ClientTarget = "Uplevel";


-- bruce (sqlwork.com)
 
In addition to this, if you google updated browser caps you will find more
complete browser caps.
 
Thank you all! I included the ClientTaget check in my base page class and
for now it works fine for me.

Nacho
 
Back
Top