SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Hybrid View

  1. #1
    SitePoint Addict
    Join Date
    Aug 2010
    0 Post(s)
    0 Thread(s)

    Z-Index Question...

    Do z-indexes only work if they're being used in the same CSS sheet?

    For instance page1.css has an element that has a z-index:1;

    and page2.css has an element that a z-index:0;

    Will this work? Or do both elements need to be in the same css page?

  2. #2
    Mouse catcher silver trophy Stevie D's Avatar
    Join Date
    Mar 2006
    Yorkshire, UK
    123 Post(s)
    1 Thread(s)
    It doesn't matter - all linked and embedded CSS will be evaluated and treated the same. It doesn't matter whether you have different elements referenced in different CSS files, or if you have one separate CSS file that deals only with z-indexes, it will work out the same.

    (Ok, that ignores the rules of precedence if you have two conflicting rules being applied to the same thing, but assuming you haven't done that, it will work out the same)


Posting Permissions

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