Posted by zroger on February 21, 2009 at 4:42am
This module takes the fuss out of creating a theme with alternate stylesheets. The module takes care of outputting the appropriate markup and javascript, leaving only the stylesheet portion of the work up to the themer. Implementing this in your theme is a simple 2 step process:
- Create stylesheet(s) for each different style. Note that each stylesheet is added to the existing set of default stylesheets.
- Add a line to your theme's info file like
styleswitcher[css][Style 2] = css/style2.css
where "Style 2" is the title associated with you style, and css/style2.css is the location of the stylesheet, relative to the theme's path.
That's it. The module will present a block with links for each of these styles. It is much like the color module; in order to use it you must have the module enabled AND use a theme that implements it.
To read more about how alternate stylesheets are implemented in browsers, see this *old* A List Apart article.
Development supported by Annertech.
Downloads
Recommended releases
Development releases
Project Information
- Maintenance status: Actively maintained
- Development status: Under active development
- Module categories: Developer, Theme Enhancements
- Reported installs: 55 sites currently report using this module. View usage statistics.
- Downloads: 1,146
- Last modified: April 13, 2012