All Caps with CSS

While text in general is hard to read when written in all caps – and considered the electronic version of yelling – using CAPS for emphasize is a handy tool.

Headers are a place where capitalization is frequently used. And to assure that your header is displayed uniformly throughout the site without having to worry about actually writing in all caps, just use CSS:

h1 {
text-transform: uppercase;
}

With this, everything that has the h1 tag applied, will appear in all caps.

Another interesting text-transformation property is "capitalize"

h1 {text-transform: capitalize;
}

With this, all your words will begin with a capital letter!

Tags: , ,

This post was written by: Andrea Barnett

This entry was posted on Tuesday, May 11th, 2010 at 10:40 am and is filed under CSS Basics, CSS Fonts, Killer CSS Tips and Tricks. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

Leave a Reply