Removing a browsers default CSS settings
I found an article a while ago by Adrian Senior called CSS: Getting Into Good Coding Habits. This is an excellent article, but the part I have found very useful is where he discusses removing the browsers default settings. I have reproduced a slightly modified version below. I now use this as a starting point for stylesheets on evey new site I develop:
html, body, ul, ol, li, p,
h1, h2, h3, h4, h5, h6,
form, fieldset, a {
margin: 0;
padding: 0;
border: 0;
}
body {
font-size: 100.01%; /* Fix for some browser bugs */
background-color: #ffffff;
}
h1, h2, h3, h4, h5, h6 {
font-weight:normal;
font-size:100%;
}
h1, h2, h3, h4, h5, h6,
form, fieldset, a {
margin: 0;
padding: 0;
border: 0;
}
body {
font-size: 100.01%; /* Fix for some browser bugs */
background-color: #ffffff;
}
h1, h2, h3, h4, h5, h6 {
font-weight:normal;
font-size:100%;
}
Comments (Comment Moderation is enabled. Your comment will not appear until approved.)
30 Oct 2007
05:20AM
Sebastiaan Naafs - van Dijk said:
31 Oct 2007
02:38AM
Kevan Stannard said:
22 Jun 2009
02:06PM
Daniel Walter Scott said:
4 Feb 2010
04:11PM
Abe said:
Add a comment
