![]() |
|
|
Resetting Browser Defaults |
|
Extreme Talker
Posts: 216
Name: Abel Mohler
Location: Asheville, North Carolina USA
|
Here is a subject that I think doesn't come up often enough.
Most professional stylesheets begin with some sort of resetting of browser defaults, in order to gain some type of uniformity (or at least an attempt at it), across mainstream browsers. The way I do it is a very simple one, using the Universal Selector (*): Code:
* {
margin: 0;
padding: 0;
}
Of course there are other defaults to the browsers besides margins and padding, especially involving borders on form elements. I usually choose to deal with these as they come up, or ignore them. The Yahoo UI team has chosen a much more extreme (and effective) method of dealing with this problem. There is a link to their code, as well as a (45 minute!) video by one of their lead developers explaining their justification behind this approach. Between what I do (very simple) and the extreme approach of the YUI folks, there are many comfortable mediums. I didn't post this thread to ask a specific question, but instead to bring attention to this issue, which I feel is an important one. Many of the example stylesheets posted by those learning the art of CSS in this forum are missing this important ingredient, and since a huge focus of our battle in this arena is cross-browser compatibility, I wanted to bring this topic up for discussion, to at least bring attention to it. I would love to hear more approaches besides the two that I mentioned. |
|
|
|
| Sponsored Links (We share ad revenue): |
|
|
Re: Resetting Browser Defaults |
|
Junior Talker
Posts: 2
|
Here are two more way to rest the browser default settings.
http://www.thechoppr.com/blog/2008/0...reset-you-css/ |
|
|
|
|
|
Re: Resetting Browser Defaults |
|
Junior Talker
Posts: 3
Name: pab
|
Eric Meyers has a great one, its pretty extensize
http://meyerweb.com/eric/thoughts/20...eset-reloaded/ |
|
|
|
| Sponsored Links (We share ad revenue): |
| Thread Tools | |
|
|
| Webmaster Resources Marketplace: |
| Software Development Company | Webhosting.UK.com |
| Web Templates | Text Link Brokers | Stock Photos |