:root

This pseudo-class is directed at the document's root element. In HTML this is <html>. For example: :root { background-color:blue; } will set the background of the whole document blue.

When tested, it worked in Firefox and Safari, but failed in IE and Opera (see the screenshots below).

Do you need help with CSS? Gain advice from Builder AU forums

Comments

1

MichaelR - 01/04/08

Surprised you didn't try IE7 that works in every case. Relying on a beta in a comparison test is dangerous.

» Report offensive content

2

eddiep - 01/04/08

Well, everithing diplayed correct in Opera 9.5 beta on my laptop ... Why didn't you used Opera 9.5 beta??? IE and FF were beta ...

» Report offensive content

3

Facilinfor - 01/04/08

"Surprised you didn't try IE7 that works in every case."

I use IE7... and it does not work...

» Report offensive content

4

Code - 02/04/08

For a site thats "by developers for developers", it's surprising that the author of this article links huge, bandwidth wasting BMPs instead of PNG which would have been much smaller in size.

http://en.wikipedia.org/wiki/Portable_Network_Graphics

» Report offensive content

5

Sambi - 02/04/08

Hi,

its unfair you used all the latest beta's or versions of IE, FF and Safari but you are using old version of Opera.

Each and every test that you gave here is working in Opera 9.5 beta.

If you make a comparsion give equal chance to everyone. Either stable versions or beta's.

Anyway good test.

» Report offensive content

6

Lana Kovacevic - 03/04/08

Thank you all for your comments. I have tested the code in Opera 9.50 Beta 1 also. You can find the results here: http://www.builderau.com.au/blogs/syslog/viewblogpost.htm?p=339270947

» Report offensive content

7

Mohan - 02/05/08

I have used almost every browser such as safari, firefox, avantgo,IE but it seems that opera is the best.

» Report offensive content

8

Abraham - 12/09/08

This all worked in Google Chrome, in case anyone is using it. All the CSS is working fine, they fixed some serious AJAX issues it had at first, but now it's fine.
Java still isn't compatible, but that's not part of this article.

CSS works perfectly.

» Report offensive content

9

Dennis - 06/02/09

<rant>It seems as if all any of these new browsers are doing is driving up development costs on what should be easy and inexpensive creation of web pages. Honestly, if Google hadn't started ignoring text inside of tables I could cut my costs in half by still using them. Tables are still the only way to easily create consistant cross-browser effects. A table cell between two others will NEVER drop out due to a 1 pixel difference in size interpretation by a browser.</rant>

» Report offensive content

10

Chris - 17/12/09

@Dennis. Maybe you just never learner how to do math. Factoring in 1px is a pretty equation. I used to strongly rely on tables, but honestly, in this day and age, that's a pathetic approach to web design.

<div>get a life</div>

» Report offensive content

Leave a comment

You must read and type the 6 chars within 0..9 and A..F

* indicates mandatory fields.

10

Chris - 17/12/09

@Dennis. Maybe you just never learner how to do math. Factoring in 1px is a pretty equation. I ... more

9

Dennis - 02/06/09

<rant>It seems as if all any of these new browsers are doing is driving up development costs on what should be ... more

8

Abraham - 09/12/08

This all worked in Google Chrome, in case anyone is using it. All the CSS is working fine, they fixed some ... more

Log in


Sign up | Forgot your password?

  • Staff Microsoft shows off IE9 preview

    This week, highlights from Microsoft's MIX10 conference and more in the Roundup. Read more »

    -- posted by Staff

  • Chris Duckett IE9's H.264 vote killed Ogg

    In a split decision by the judges, the winner of the W3C/WHATWG video codec consensus is H.264, taking home the future of video playback on the internet while loser Ogg goes home with nothing but thoughts of what might have been. Read more »

    -- posted by Chris Duckett

  • Staff Google launches Apps Marketplace

    Google launches and app store, while Mozilla plans to re-write its open-source license. More of this week's news in the Roundup. Read more »

    -- posted by Staff

What's on?

  • Optus Deal

    Broadband + home phone + PlayStation®3 in a single package price!