tags:

views:

222

answers:

4

Here's the situation.

  1. I made three style sheets for each of the three pages I am currently working on. One that works in IE8/Safari/Opera/Firefox. One that works in IE7 and one which if used alone works on IE6

  2. I tested everything on www.xenocode.com/browsers and that sites' IE 6 and 7 emulators.

3 I used a variation of the article's suggestions for a way to make all the sheets work. (In the section:

http://www.thesitewizard.com/css/excludecss.shtml

The problem is that while it calls up the proper css for IE 8 and IE 7 online (It works just fine directly off my computer), it can't seem to call up the code for IE6 properly online causing the layout to be messed up in IE 6 (Or at least the emulator on xenocode.com.

Is there a better method?

(Can't show you the full page, due to my client being adamant about not showing it until the project is finished.)

A: 

You want to have IE6 specific CSS? Also, please consider using Microsoft SuperPreview to locally see how your design looks in various versions of IE6.

BeefTurkey
+1  A: 

Assuming you are using browser conditional statements...

I would check that the emulator your using is able to interpret browser conditional statements. If unsure you could always disable all other stylesheets and link normally (using the link tag) to just the IE6 stylesheet and then test

Nick Allen - Tungle139
Actually, I did that. It works fine both on and offline for the IE6 emulator if i JUST have the ie6 css be linked up.
Are you putting you IE6 conditional statement below the other stylesheets? otherwise because of the cascading nature of CSS the other styles would overide anything you declared in the IE6 sheet, nullifying the effect
Nick Allen - Tungle139
A: 

You can use these css selection tags for the specific Browser version for IE.

<!--[if IE 6]><link rel="stylesheet" type="text/css" href="/css/ie60.css" /><![endif]-->
<!--[if IE 5.5000]><link rel="stylesheet" type="text/css" href="/css/ie55.css" /><![endif]-->
<!--[if lt IE 5.5000]><link rel="stylesheet" type="text/css" href="/css/ie50.css" /><![endif]-->
Barbaros Alp
You can also check this Modular Css slide show http://www.barbarosalp.com/post/2009/02/26/Moduler-CSS.aspx
Barbaros Alp
How do I alter the above code for Mozilla/Firefox?
To target all non-IE (not just Firefox), use <![if !IE]>(non-IE stylesheet here)<![endif]>
David Kolar
A: 

http://rafael.adm.br/css_browser_selector/

I love this thing because it lets me define granularly all the changes I want for different browsers / operating systems.

MrMaksimize