bigsilk Posted August 22, 2009 Report Share Posted August 22, 2009 I'm learning CSS on my own and I use both intermittently, and I don't know why...They seem to do pretty much the same thing. Link to comment Share on other sites More sharing options...
Synook Posted August 22, 2009 Report Share Posted August 22, 2009 A single class can be used multiple elements, while an ID can only be used once. IDs are easier to search for when you use the DOM (e.g. with JavaScript). Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now