CSS or: How I Learned to Stop Worrying and Love the W3C.

Way back in my middle school days, I can remember faux coding in Dreamweaver thinking “Wow, this is so complex”. I never thought there could be bugs with HTML or that a coding language needed updating. I thought it just…existed, I guess.

Well as it turns out people much smarter than I found out there were various problems that needed to be solved like formatting that could be done in HTML, but was a nightmare for developers. So the World Wide Web Consortium (W3C) created CSS. W3C could be called the congress of web development. They handle the standards and protocols for the web. This helps ensure that everyone is on the same page and people aren’t doing more work then they have to.

I know many of you aren’t web designers or developers…and I’m hardly one myself. But I decided to write this article not because I’m wanting to bore you, but because I genuinely find it fascinating the impact that CSS has had on web developing.

CSS stands for Cascading Style Sheets, and what it does is it tell the browser how to display certain html elements such as a paragraph or <p>. That’s as simple as it can really be explained. Before CSS things like color and font attributes could be done in HTML, but as I said before it caused horrific coding environments for developers. CSS helped by reducing the amount of code within the content of the website. Instead it was handled by an file outside of the HTML. To get a better understanding of why we really need CSS and how it’s impacted us, let me show you what our site would look like without it.

css_comparison

You can plainly see that the one without CSS is still functional…but not practical. Now i’ve been saying CSS and HTML but really CSS also works with XHTML and XML, but that’s beyond the scope of this post, however, to help you better understand how CSS works lets take a look at this:

Screen shot 2010-03-11 at 3.31.14 AM

Now basically what this means is the element with the class “featurepost” will have a background color of #FCFEE3, It will have 5 pixels of spacing on the top, bottom and left sides, as well as a 1 pixel dotted border around the element with the color #b6b6b6. The html to incorporate something like this, assuming the stylesheet is linked somewhere in the document, would look as simple as this <div class=”featurepost”>Yadda</div>

All browsers these days support CSS. Most, if not all, of the big name browsers support CSS 2.1 as well as some CSS 3, which is currently still in development. But what peaks my interest is the question of how these browsers decide on implementing this code. In a nutshell, if browsers don’t unify how their code is implemented…then it’s the exact opposite of what CSS was designed to help with in the first place.

For instance Mozilla since Firefox 3.5 has been pursuing it’s idea that Ogg Theora will overtake H.264. Which in theory is fine because Ogg Theora is an Open Source Codec, whereas H.264 is commercial closed source codec. But the difference lies when you ask “When will browsers become unified?” The answer simply is that they won’t. These are companies seeking to make profit, and in order to do so they must differentiate from the pack.

With the CSS3 border-radius declaration, we already must distinguish between Mozilla (Firefox) and Webkit (Safari/Chrome) browsers, this is probably only due to CSS3 still being in development. It does left this to be said though, if this were to continue we would be doing three times the work. I just feel that everything is pointing in a digression in web standards and who is going to be suffering? Everyone will, because Developers will have to do more work, which means websites will probably look worse, and everything will just be as complex as when I first started in middle school. Hopefully the W3C’s vision for “One Web” will hold true.

Let me know what you thought of this in the comments. It’s probably extremely boring, but I think a couple people out there will find it interesting. ^_^

11 thoughts on “CSS or: How I Learned to Stop Worrying and Love the W3C.”

  1. LISTEN TO THIS DUDE because in December you all almost got a faceful of WaCkY non-CSS when I broke part of the website :<

    MORAL OF THE STORY: LOCAL IS SMARTER THAN ME AND THEREFORE MUST BE THOUSANDS OF TIMES SMARTER THAN YOU

  2. This was interesting i must say. Also what’s with all the dr.strangelove references i’ve been seeing, now here too?! (I love the movie though ^-^)

Leave a Reply