brown2005 Posted September 15, 2007 Share Posted September 15, 2007 html, div, p, table, form, li, ul, img { margin: 0px; padding: 0px; } ive been told to use this as my first bit of css code. is this correct? Quote Link to comment https://forums.phpfreaks.com/topic/69485-css-clear/ Share on other sites More sharing options...
ToonMariner Posted September 15, 2007 Share Posted September 15, 2007 * { padding: 0; margin: 0; } is just as effective.... and easier Quote Link to comment https://forums.phpfreaks.com/topic/69485-css-clear/#findComment-349211 Share on other sites More sharing options...
brown2005 Posted September 16, 2007 Author Share Posted September 16, 2007 so if i use the * that will clear everything then? Quote Link to comment https://forums.phpfreaks.com/topic/69485-css-clear/#findComment-349558 Share on other sites More sharing options...
bronzemonkey Posted September 16, 2007 Share Posted September 16, 2007 It is good practice to use a "reset" (clear is something else!) to avoid default browser styles messing with your design. Eric Meyer uses this css reset to get you started with a "blank canvas"...it's pretty handy and you can modify it for the needs of your project. http://meyerweb.com/eric/thoughts/2007/05/01/reset-reloaded/ Quote Link to comment https://forums.phpfreaks.com/topic/69485-css-clear/#findComment-349578 Share on other sites More sharing options...
brown2005 Posted September 19, 2007 Author Share Posted September 19, 2007 on that page it has 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, 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-weight: inherit; font-style: inherit; font-size: 100%; font-family: inherit; vertical-align: baseline; } can you not use *{ margin: 0; padding: 0; border: 0; outline: 0; font-weight: inherit; font-style: inherit; font-size: 100%; font-family: inherit; vertical-align: baseline; } Quote Link to comment https://forums.phpfreaks.com/topic/69485-css-clear/#findComment-351057 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.