Home arrow Style Sheets arrow Double Vision – Give the Browsers CSS They Can Digest

Double Vision – Give the Browsers CSS They Can Digest

Some but not all browsers support CSS2. You can deliberately code your website so that users of either kind of browser will see pages that are appropriate for what their browser can handle. Older browsers won't gag, but you will still be able to take advantage of what you can do with CSS2 in the newer browsers. Read on to find out how.

Author Info:
By: Chris Heilmann
Rating: 5 stars5 stars5 stars5 stars5 stars / 15
February 22, 2005
  1. · Double Vision – Give the Browsers CSS They Can Digest
  2. · The way of the dark side – code forking
  3. · The way of confusion – browser hacks
  4. · The way into the future – progressive enhancement
  5. · The child selector
  6. · Enhancing with the child selector
  7. · The screen display style sheet
  8. · The print style sheet

print this article

Double Vision – Give the Browsers CSS They Can Digest
(Page 1 of 8 )

When surfing the Web, one might encounter websites that look completely different in Microsoft Internet Explorer and Firefox/Opera. We don’t mean websites with bugs, or ones that were developed for MSIE only. We’re talking about websites deliberately showing a different style in the two of them. One example would be this CSSZengarden submission: (http://www.csszengarden.com/?cssfile=http://icant.co.uk/zen/sample.css).


The reason for these websites is to show how much more a browser that properly supports CSS2 can offer. This technique is called progressive enhancement (http://css-discuss.incutio.com/?page=ProgressiveEnhancement), or graceful degredation (http://www.anybrowser.org/campaign/
) - depending on which way you look at it – from newer to older or older to newer browser.


It is nothing new - clever Web developers have done to same to send a basic style sheet to older browsers like Netscape 4, and a different one to more advanced browsers:


<link rel="StyleSheet" href="basic.css" type="text/css">

<style type=”text/css”>@import “advanced.css”;</style>

Netscape 4 does not grasp the @import directive and applies basic.css exclusively. More modern browsers also read advanced.css and overwrite or re-use what has been defined in basic.css. The same can be done today for yet a newer breed of browser. This can be achieved in several ways. 

blog comments powered by Disqus

- CSS Padding Overview
- CSS: Margins Overview
- Top CSS3 Button Tutorials
- More Top CSS3 Tutorials for Animation and Im...
- CSS Mega Menus: Adding Extra Sections
- CSS Mega Menus
- CSS3 Accordian Menu: Horizontally Display Hy...
- CSS Combinators: Working with Child Combinat...
- CSS Combinators: Using General Siblings
- Intro to CSS Combinators
- CSS Semicircles and Web Page Headers
- Drawing Circular Shapes with CSS3 and Border...
- More CSS Pagination Link Templates
- CSS Pagination Links
- Animated CSS3 Image Gallery: Advanced Transi...

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 

Developer Shed Affiliates


© 2003-2019 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials