cncr Posted March 19, 2011 Share Posted March 19, 2011 Css..2................if say you are styling a list ( external file ) and the padding =0px...................why put the code if it has no value ?Or am I missing something ? Link to comment Share on other sites More sharing options...
jeffman Posted March 19, 2011 Share Posted March 19, 2011 Many elements have default values that create the default appearance. An ordinary list item is indented from the left by a certain value. Browser makers determine what that value is, and what CSS property is used to create that appearance. A problem is that all browsers do not use the same values or the same properties. It is very common for developers to reset the margin and padding of ALL elements to 0 and then redefine any those values for any specific elements that require them. The reset looks like this: * { padding: 0; margin: 0;} I do not know why a developer would single out a list for reset, unless (1) he isn't familiar with the general concept, or (2) the list inherits a value from a ruleset that you have not noticed, or which isn't included in the part of the library that you have. Link to comment Share on other sites More sharing options...
cncr Posted March 19, 2011 Author Share Posted March 19, 2011 Many elements have default values that create the default appearance. An ordinary list item is indented from the left by a certain value. Browser makers determine what that value is, and what CSS property is used to create that appearance. A problem is that all browsers do not use the same values or the same properties. It is very common for developers to reset the margin and padding of ALL elements to 0 and then redefine any those values for any specific elements that require them. The reset looks like this:* { padding = 0; margin = 0;} I do not know why a developer would single out a list for reset, unless (1) he isn't familiar with the general concept, or (2) the list inherits a value from a ruleset that you have not noticed, or which isn't included in the part of the library that you have. So what ur saying is that : padding=0px is like a Crossbrowser RESET to >>> default appearance ? Link to comment Share on other sites More sharing options...
jeffman Posted March 19, 2011 Share Posted March 19, 2011 I'm saying that a reset might be the developer's intention. I haven't seen the complete document, so it's impossible to be sure. Link to comment Share on other sites More sharing options...
Fmdpa Posted March 19, 2011 Share Posted March 19, 2011 What's up with the assignment operator? Shouldn't it be: * { padding: 0; margin: 0;} Link to comment Share on other sites More sharing options...
jeffman Posted March 19, 2011 Share Posted March 19, 2011 What's up is I had a brain fart. Link to comment Share on other sites More sharing options...
Fmdpa Posted March 19, 2011 Share Posted March 19, 2011 ...like I just saw JSG using the "Language" attribute in a <script> tag. I'm not sure what was up with that! Link to comment Share on other sites More sharing options...
cncr Posted March 19, 2011 Author Share Posted March 19, 2011 I'm saying that a reset might be the developer's intention. I haven't seen the complete document, so it's impossible to be sure. Link to comment Share on other sites More sharing options...
birbal Posted March 20, 2011 Share Posted March 20, 2011 ...like I just saw JSG using the "Language" attribute in a <script> tag. I'm not sure what was up with that!i think its using xml and language is its custom attributes. and later on that any xslt stylesheet will be applied to that and xml document and will use it as type='text/javscript' Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.