• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 262
  • Last Modified:

CSS attributes possible for a given HTML tag

Hello all,

I am new to CSS and I am going through some CSS tutorials/books. I was wondering if there is a resource online that lists all the possible attribute styles(like width, position, border..) that can be applied to a given HTML tag. Everytime I go through a tutorial, I find bits and pieces of information and new CSS attributes.

I am a programmer and from that perspective, Is there any hierarcy like.
1 a base set of attributes that are common to all tags and...  
2 some tags have more specific attributes.

(Other than w3schools.com and w3c)

Thanks
0
tvr1729
Asked:
tvr1729
  • 2
1 Solution
 
David S.Commented:
Good question. Theoretically all properties can apply to all elements. However, some properties only apply when an element has certain other properties set. For example, the width and height properties don't apply to inline elements, like <a>s and <span>s are by default. Another example would be that the top, left, right, bottom, and z-index properties don't apply to non-positioned elements (elements that don't have their position property set to a valid value other than "static", which is the default value). For yet another example, border-collapse only applies to elements with display:table or display:inline-table (IE7 doesn't support those, but IE8 will).

Here's a very good CSS Reference site: http://reference.sitepoint.com/css
0
 
David S.Commented:
To clarify what I said, IE5+ do support border-collapse. They just have it bound directly to <table> elements instead of to display:table and display:inline-table like other browsers do.
0
 
tvr1729Author Commented:
Thanks!
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now