Welcome to WebmasterWorld Guest from 22.214.171.124
Forum Moderators: not2easy
I can't seem to find a tutorial online for this either. Any ideas if this can be accomplished with CSS? My thought was to have three separate stylesheets, but that seems kind of cumbersome.
<div class="main_content,' . <?php echo $custom_text_class;?> . '">
Which would output: <div class="main_content,small_text">
And set $custom_text_class based on the user's cookie or session variable or whatever.
The two tutorials I used were:
Hope that helps you out!
It may take me a while to get the first one done, but any future sites I make using this should be faster and easier.
You could use relative font sizes instead of absolute ones and allow the visitor to set -depending on his/her needs- an appropriate font size as default.
This is true, too. In the site I did, I made sure that that option was also available - however, the client *wanted* an "enlarge text" button. The client's (in my case) customer base were elderly, and apparently a lot of them (prior to redesign) had no idea you could change the font sizes within the browser - they would complain to the client about the "tiny font sizes". So they wanted the button.
Sure, there are people out there who know how to do it, but for the ones who don't, it's a nice option to have :)
W3C has a page about it (and has some great links to illustrate the arguments)
There is of course also their accessibility project and that lists a nice matrix you could use to tell your visitor how to change the font-size on the fly.
[Hope it's OK to reference w3c, I'm not associated with them at all]