YOU MAKE IT. WE MAKE IT WORK.
IDs and Classes
IDs and Classes can be mixed up a lot if you do not know what you are doing. You cannot use an ID more than once in an XHTML document or it renders the page invalid. A perfect use for this would be for a banner. Classes on the other hand were designed for to be used multiple times on a page. An ideal class would be for a content heading used numerous times.
To make an ID in the CSS you must start it off with the pound sign (#). Classes begin with a period (.)
CSS Code
#id {
}
.class {
}
XHTML Code
<div id=”id”></div>
<div class=”class”></div>
| Print article | This entry was posted by Kyle on July 18, 2007 at 5:33 am, and is filed under CSS, Coding, Validating, XHTML. Follow any responses to this post through RSS 2.0. You can leave a response or trackback from your own site. |

