Digital Ocean logo

CSS-Tricks is joining the DigitalOcean community! We are so excited to be joining forces. Learn more about this change here. As a special welcome offer, enjoy $100 of free credit to try DigitalOcean on us.

Un-bloat CSS by using multiple classes

Let’s say you need six different 100px square boxes with different characteristics:

  • Red with Border
  • Blue with Border
  • Green with Border
  • Red without Border
  • Blue without Border
  • Green without Border

You COULD create a unique class for each of these, …

Avatar of Chris Coyier
Chris Coyier on (Updated on )

Font Rendering Differences: Firefox vs. IE vs. Safari

You can get pretty specific when declaring how you want text to look with CSS:

p {
  font-family: Verdana;
  background-color: #7A2121;
  color: #B93333;
  text-decoration: underline;
  word-spacing: Normal;
  text-align: left;
  letter-spacing: 1px;
  text-indent: 15px;
  line-height: 16px;
  font-size: 10px;
  font-weight: bold;
  font-style: 
Avatar of Chris Coyier
Chris Coyier on (Updated on )

Totally Ridiculous: CSS MySpace Modifications

This is old news, but is worth of revisiting because of it’s preposterousness. You are able to add CSS to your MySpace pages. Cool. But where do you do that? Is there some little fun CSS editor they built in? …

Avatar of Chris Coyier
Chris Coyier on (Updated on )