tags:

views:

102

answers:

2

I know and use eric meyer CSS reset, but is there any more things which would be good to add in reset css? and can save our time and increase compatibility.

This is default meyer's latest CSS reset code.

/* v1.0 | 20080212 */

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td {
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    font-size: 100%;
    vertical-align: baseline;
    background: transparent;
}
body {
    line-height: 1;
}
ol, ul {
    list-style: none;
}
blockquote, q {
    quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
    content: '';
    content: none;
}

/* remember to define focus styles! */
:focus {
    outline: 0;
}

/* remember to highlight inserts somehow! */
ins {
    text-decoration: none;
}
del {
    text-decoration: line-through;
}

/* tables still need 'cellspacing="0"' in the markup */
table {
    border-collapse: collapse;
    border-spacing: 0;
}

and i also add a img {border:0} with this reset.

A: 

Take a look at Yahoo's YUI 2: Reset CSS.

Nick Presta
my question is not which css reset is best. i'm asking to add more things along with eric's reset. i would not replace eric reset with yui reset
metal-gear-solid
You can look at Yahoo's reset and incorporate things you like and things that are useful. I'm not going to code a whole reset.css for you, and I doubt anyone else will either. You have to be resourceful and look at things already made and learn from them.
Nick Presta
+2  A: 

I concur with Nick's answer. You should seriously consider using a yahoo's reset (or some other reputable source). Frankly they have more resources than you to test in a variety of browsers and environments. And they'll keep it updated as new browsers come out. Finally, you can take advantage of their free super-fast CDN:

<link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/combo?3.1.0/build/cssreset/reset-min.css"&gt;
Keltex
but yahoo's CSS resets are not valid.
metal-gear-solid
@metal-gear-solid - Can you explain what you mean by "not valid"?
Keltex
metal-gear-solid
@metal-gear-solid - I see. That asterisk that the validator calls out is for IE 7 and lower. I guess you can remove it if you aren't as concerned about those browser versions. I assume that Yahoo will remove this too when they move IE 7 out of their so-called "A-Level" browser list.
Keltex
@Keltex - and yahoo's reset doesn't have reset for `<table>` , and I need css reset for all browser including IE6.
metal-gear-solid
@metal-gear-solid: It does include a reset for table: table{border-collapse:collapse;border-spacing:0;}
Keltex
oh yes it was my mistake sorry.
metal-gear-solid
+1 for giving good info and link
metal-gear-solid