Style Sheets
  Home arrow Style Sheets arrow Working with Multiple Style Sheets
IBM Developerworks
Iron Speed
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Dedicated Servers  
Download TestComplete 
IBM® developerWorks 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
STYLE SHEETS

Working with Multiple Style Sheets
By: Alejandro Gervasio
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 1
    2007-09-11

    Table of Contents:
  • Working with Multiple Style Sheets
  • Working with alternate style sheets
  • Switching alternate style sheets in a cross-browser fashion: defining a basic JavaScript function
  • Swapping alternate style sheets

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    Iron Speed
     
    ADVERTISEMENT

    Free Web 2.0 Code Generator! Generate data entry and reporting .NET Web apps in minutes. Quickly create visually stunning, feature-rich apps that are easy to customize and ready to deploy. Download Now!

    Working with Multiple Style Sheets
    (Page 1 of 4 )

    As the Web evolves steadily, more and more sites are providing their visitors with different mechanisms for customizing their surfing experience. Nowadays, it's quite common to visit a web site that allows users to change background and foreground colors of specific sections of that site, alter the size of the font, or even modify the position of certain elements by implementing "draggable" user interfaces.

    Definitely, this level of customization is more evident when visitors are allowed to modify (only partially) the visual appearance of a given web site. This implies the existence behind the scenes of an application that manipulates the CSS styles associated with the web site.

    Of course there are different approaches that can be used for changing the CSS styles of a specific web site. These range from the modification of a few elements to altering the visual appearance of the entire web document. However, one of the most popular techniques used these days takes advantage of multiple style sheets, which can be alternated by the mean of some embedded tools provided by the web surfer's own browser (Mozilla Firefox is a good example of this) and via server/client-side scripting.

    As you can see, providing users with the capacity for swapping complete style sheets can be quite useful in certain cases, particularly if you're trying to make your web site more customizable and accessible to your visitors. Definitely, you'll have to agree with me that the topic is not only interesting, but implies learning different approaches to changing the style sheets of a given web document.

    So, assuming that you might want to learn different methodologies for switching complete style sheets, in this series, which is made up of three tutorials, I'll be demonstrating with numerous easy-to-follow examples how to alternate between the distinct style sheets assigned to a selected web document. This will provide you with the required background to incorporate this capacity into your own web applications.

    With the preliminaries already out of the way, let's learn together how to manipulate several style sheets attached to a given web page. You won't disappointed, trust me!

    More Style Sheets Articles
    More By Alejandro Gervasio


       · This first part of the series offers a friendly introduction to swapping between...
     

    STYLE SHEETS ARTICLES

    - Using PNG Images to Build Background Effects
    - CSS: Continuing the Clarification of CSS Cla...
    - CSS: Top Secret Classification
    - CSS: Dimensions
    - CSS: Margins and Padding
    - CSS: Crossing the Border
    - CSS: Text, Fonts, and Tables
    - CSS: Working with Text
    - CSS: Backgrounds
    - CSS for the Newbie
    - Styling Web Page Headers with Transparent Ba...
    - Creating Angled Corners with Transparent Bac...
    - Style Sheets for a Useful Links Page
    - Modifying the Look and Feel of Individual El...
    - Using Persistent Styles with Multiple Style ...


     
    Accelerating Trading Partner Performance
     
    Competing on Analytics
     
    Cost Effective Scaling with Virtualization and Coyote Point Systems
     
    Five Checkpoints to Implementing IP Telephony
     
    Hosted Email Security: Staying Ahead of New Threats
     





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway