When I began web development 4 years ago I started out learning HTML and CSS on a ‘Web Design & Programming’ forum, the forum was full of very elitist people who would completely rip apart a design and give harsh (but very useful) criticism (usually to do with web standards) if the code was not 100% perfect.
By learning from other people’s mistakes and having every small flaw pointed out I became quite an elitist too, but I think when learning how to make websites it’s very important to have a strict set of ‘rules’ that you will always follow.
Here’s my (short) list of elitist rules:
I used to follow that list religiously until quite recently. Until I realised that it just isn’t practical to do everything perfectly 100% of the time.
Sure I still use a text editor to write my code, I still make sure everything validates, I still think less markup is better and I still think WYSIWYG sucks, but I’ve stopped getting hung up on the things that really don’t matter anymore. Now that I know html and css like the back of my hand I’ve started looking for, and using, things other people have made that I can use to make my life easier.
My latest discovery was the Blueprint CSS framework. Back in the day I would have never looked twice at a CSS framework but lately I’ve needed to turn out a lot of layouts and it really has saved me so much time.
It works by using a pre-made grid stylesheet with a load of class selectors that you can attach to your elements and because you can add multiple css classes you really can build whatever layout you want in a very short time.
The following code is all you need to create quite a useful layout.
Sure it uses a quite a lot of divs but it validates and takes about 5 minutes to make (if that). From here I create a stylesheet that can be used purely for adding the page styles instead of mixing style and layout.
It’s only really useful for more complex layouts but I loooooove using it.
I really just wanted an excuse to post some highlighted code. ha