There are two approaches to truing a bicycle wheel. The first is to just identify any loose spokes and tighten them up. Then start tightening or loosening spokes and spinning the wheel to see if there’s any effect. Continue this trial and error approach for several hours and you might end up with a true wheel.
The other approach is to have someone teach you the principles of how it works and then spend 15 or 20 minutes systematically getting your wheel true and round. I’ve tried both and I recommend doing it this way.
CSS is just like this. You can get your page to look the way you want through trial and error and piling on more classes, adding more divs, and generally making a mess of things. It’ll take a long time but in the end it might work. Or you can learn the CSS Specificity rules and the principles behind CSS selectors and get it done in a fraction of the time and with much cleaner code. Again, I’ve tried both approaches and I’d recommend the second.
This article in Smashing Magazine is a good read and a great reference. I’m going to keep it handy. I predict the process of building my next iPhone web app will take a lot less time and be a little more sane.



