On Tuesday, November 14, 2006 8:14 AM ReynierPM <> said:

> .header_b
> {
>       display: inline;
> }
> 
> So I need to change it to block in IE. Can any help me with this?
> Cheers and thanks in advance

Within CSS you can do the following to apply styles to IE only. (This
hack may be fixed in IE7 not sure.)

.header_b
{
        display: inline; /* non-IE */
        _display: block; /* IE only */
}

Adding a '_' to any style makes all non-IE browsers ignore the rule.

On the other hand if that will not work for you you'll need to do some
simple object detection in your js code to detect an object that only IE
has. If the detection returns true you can have jQuery change the style
on '.header_b'.

There are a good series of videos on Yahoo! Video by Douglas Crockford
called "Theory of the DOM". Comes in three parts. In it he talks about
this kind of thing (albeit briefly).

1 of 3
http://video.yahoo.com/video/play?vid=cccd4aa02a3993ab06e56af731346f78.9
92708

2 of 3
http://video.yahoo.com/video/play?vid=cccd4aa02a3993ab06e56af731346f78.9
96002

3 of 3
http://video.yahoo.com/video/play?vid=cccd4aa02a3993ab06e56af731346f78.9
96008



Chris.

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to