Providing CSS for just Internet Explorer

20 Sep 2004

(Disclaimer – although this didn’t turn out to be the valid replacement for the underscore hack that I hoped it was, I thought I’d leave the post here as proof of what happens when you don’t check your facts thoroughly enough. Or more specifically, when you’re so tired, that you confuse a vaild HTML result to be valid CSS – hey ho!)

Today, I had one of those little CSS accidents, which led me to discover that an easy way to provide css for only IE (PC and Mac 5, 5.5 and 6) is to simply to add a comma after the the selector, but before the opening brace:

div, {
	width: 80%;

Mozilla, Opera and Safari ignore the rule. It validates too!). I hope this is useful to someone.

The fact that IE 5 Mac applies the rule as well, could reduce its usefulness. If you have time, please test it further and let me know your results.

Recent Posts

The Infinite Canvas

09 Feb 2018

Blade Runner 2049

14 Oct 2017

iPad Pro Pencil loop

11 Oct 2017

Troika #32: Tearjerker

04 Oct 2017

Troika #31: Dusk

06 Sep 2017

Icon Design Process talk at Reasons To 2017

06 Sep 2017

Instagram Hickstagram

  • 22 Mar 2018

    Goodbye Coco, you were a marvellous GP 😞

  • 21 Mar 2018

  • 20 Mar 2018

  • 16 Mar 2018

    The Clientele with @corinpilling at the Scala last night were mesmerising! It also made me realise how great a guitarist Alasdair MacLean is!

  • 13 Mar 2018

    Hold me…

  • 13 Mar 2018

  • 11 Mar 2018

    Must. Push. Button.

  • 11 Mar 2018

    Dinner in the Oxford’s. Happy Mother’s Day @hicksleigh! (It was the best one of Dan - honest)

  • 11 Mar 2018

    She didn’t have a clue

  • 10 Mar 2018

    You paint a great mural, and some idiot adds their ugly tag to the little of space you left to balance the composition.

Contact us

Call Jon on +44 (0)7917 391536, email or tweet @hicksdesign.

Alternatively, pop in for tea and cake at the studio…

Wenrisc House
Meadow Court
Witney, OX28 6ER
United Kingdom