• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter Nine. CSS Basics > Relative and Absolute File References

Relative and Absolute File References

When creating the initial CSS, we use relative image file references because we're working on our desktop, not on a staging server. The final style sheet we create in Chapter 10 will use absolute (not relative) file references to avoid bugs in old browsers that misunderstand relative links in CSS.

The fact that old browsers bungle relative links in CSS files is another good reason to turn the accepted wisdom on its head and preview your work in good, rather than bad, browsers. Using the old method (“test in your worst browser first”), if you designed your pages offline and consequently used relative file references, the browser would botch those references, images would fail to appear, and you might spend hours trying to figure out what was “wrong” with your style sheet, when in fact nothing was wrong with it.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint