SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Wizard bronze trophy PicnicTutorials's Avatar
    Join Date
    Dec 2007
    Location
    Carlsbad, California, United States
    Posts
    3,658
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)

    Is :root a completely safe hack for IE8 and modeern browsers?

    #home .column {
    margin-right:5px; /* IE8 */
    }
    :root #home .column {
    margin-right:8px; /* Modern */
    }

    Any browsers or situations that I or others have not thought of? To me it seems perfectly safe. Much like *html for IE6 was. Only difference here is order matters as your not just feeding a single browsers a rule - your overwriting the previous. Now I'm using this 3 times in my sheet. And I forsee a few more. So just double checking. If its not totally safe I'll just do the class on the html for ie.

  2. #2
    Barefoot on the Moon! silver trophy Force Flow's Avatar
    Join Date
    Jul 2003
    Location
    Northeastern USA
    Posts
    4,617
    Mentioned
    56 Post(s)
    Tagged
    1 Thread(s)
    Honestly, I would use IE conditionals and put CSS code intended for IE in its own stylesheet, rather than rely on hacks that might break later.
    Visit The Blog | Follow On Twitter
    301tool 1.1.5 - URL redirector & shortener (PHP/MySQL)
    Can be hosted on and utilize your own domain

  3. #3
    SitePoint Wizard bronze trophy PicnicTutorials's Avatar
    Join Date
    Dec 2007
    Location
    Carlsbad, California, United States
    Posts
    3,658
    Mentioned
    15 Post(s)
    Tagged
    0 Thread(s)
    Ya I don't like hacks either. But honestly IE8 will never support :root. So I see nothing to ever break.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •