css switch (php only)

mainvisPersonally, I am very fond of Style Sheet Switchers (I’ve been meaning to put one on this site for ages now, oh to have more hours in the day! I will find the time – one day). For me – they add a certain playful touch to the site if done creatively. They are however much more important functions to consider so a style sheet switch function is not only a little bit of eye candy or simply a superficial feature but can also add to the accessibility of a website. It is good to offer an alternative colour scheme which would switch the page from light coloured text on a dark background to a dark coloured text on a light background, for example.

With a lot of different options and techniques out there I would still favour a simple switch using only PHP.  This will work reliably with or without enabled Javascript. I’ve put together a demo which also includes the steps and code snippets.

» view tutorial & demo

22/06/2009 blog,handcoding

2 Responses to “css switch (php only)”

  1. Gravatar ilze says:

    Thanks Prisca for tutorial:)
    I will try definitely.

  2. Gravatar prisca says:

    Ilze, you’ll have fun with this one – works beautifully :)
    and do show us what you’ll be doing with it ;)

Leave a Reply

graphiceyedea prisca schmarsow – portfolio

portfolio