CSS and the Yahoo YUI 2 Reset CSS

While searching around the Internet for the best way to style a certain something, I happened upon the YUI2 Reset CSS.  The Reset CSS’s main goal is to help alleviate some of the problems that come from trying to do CSS that works for as many browsers as possible.

The problem web developers and designers have today is that there are so many browsers variations on the market.  With each having a varying level of support for CSS standards, this makes the developers job more difficult.  Add to that the fact that a single problem with your CSS could cause a cascade of issues through the rest of the CSS and onto the screen.

Internet Explorer is a notoriously bad browser, as everyone in the world may know by now.  The reason it’s a terrible browser is due to the lack of conformity to CSS standards.  Imagine you expect something to behave one way, and it does in every other browser, except Internet Explorer.  That’s what Internet Explorer does.  It either ignores some CSS commands completely, or does something way off the mark of what was intended. (I’m making the assumption here that Mozilla got it right and MS is wrong)

I’ve had my panties in a bunch several times thanks to Internet Explorer.

What the Yahoo YUI 2 Reset CSS file does is level everything to a known starting point.  When you include the Reset CSS file in your markup, you are essentially saying, “Alright all you browsers of the world, we’re all going to start on the same page, hear me?”.  This helps by allowing the developer to start at a known point, and not from one browser having 5px margins from the start, while another may start with 0px.  By including the Reset CSS, every browser will start with 0px (for example), giving us a great place to start from as developers and designers.

The following video is about 42 minutes long and covers some really good information about CSS and then goes into using the YUI 2 Reset CSS and other CSS files they have available.

Nate Koechley: “The YUI CSS Foundation” @ Yahoo! Video

This is important to all of us because we want our visitors to have the same experience, regardless of the browser they may come to us with, or the operating system they may be using.

Maybe Microsoft will get it right with the next version of Internet Explorer.  I’m not holding my breath though.

About

Wayne John is a health coach for people that want to lose weight, gain weight, improve athletic performance, or simply maintain a healthy lifestyle. Wayne has lost over 55 pounds and improves his current health every day by using simple, straight-forward techniques that anyone can integrate into their lives to achieve the same. Contact Wayne today to realize your own health and fitness goals, or get started now by completing and submitting the free Wellness Profile. He also has been developing websites since 1995 and programming solutions for clients even longer. He'd rather be outside having fun in the sun though.

Tagged with: , , , , ,
Posted in Web Development Tips
4 comments on “CSS and the Yahoo YUI 2 Reset CSS
  1. Pon from VB
    Twitter:
    says:

    Though I know a very little about CSS, I know that Microsoft is trying to address this issue in IE 9. But the idea of resetting all the browsers to a common initial state is a nice idea.

  2. Nick from Web Hosting Promotions says:

    This would help bring some of the older Internet Explorer versions (still too many people using IE 6) up to par with the rest of the world.

  3. Dillard Cranston from spanish learning software
    Twitter:
    says:

    Well, I watched the entire video, and I must admit, I started watching it thinking it would probably be boring. While it wasn’t the entertainment of the year, I was pleasantly surprised to have found some great tools for web development. I’m very intrigued with the idea of using not only Reset, but Grids and Fonts as well.

    What I really like about the CSS system that they have provided is that if I use it, it will provide me with a personal standard and a consistency that I would not otherwise have. And not only that, but the way Grids allows you to create the structure of a webpage very quickly is really neat!

    So I’m glad that I happened across this webpage, because before this evening, I didn’t know the YUI libraries even existed.

  4. Tom from orlando searchlights
    Twitter:
    says:

    This actually a pretty cool little file. I skimmed through the video and it was really interesting as ell. I will have to go back to it and watch it in more detail.

    It has always annoyed me that browsers implement W3C standards differently, or only only as far as it is easy for them to implement. I guess they all have their own goals, speed, security, etc. But, IE has always been the worst of them all.

    When i make a change on a site, I sometimes forget to go back and check it on “all” the major browsers. When i do forget, invariable there is a problem.

    So, I can see that this could be really helpful.

    Thanks.