In a CSS which format takes precendence over the other, and can you reverse the precendence? Here is an example of class as Canvas and Id as header. I would like the header format to appear, but it seems to be canceled out by whatever I do in the Canvas section. Any help or a direction would be really appreciated. /* * canvas **/ body { font-size: 10pt; background-color: #0033CC; } table.canvas { width: 95%; border: solid 1px DimGray; border-collapse: collapse; padding: 0px 0px 0px 0px; margin: 0px auto 0px auto; background-color: #0033CC; } /* * header **/ #header { background-color: #0033CC; font-family: Verdana, Arial, Helvetica, sans-serif; color: #FFFFFF; text-decoration: none; font-size: 12px; font-weight: bold; Code (markup):
Here's a page about it, http://css-demos.jonra.com/css-id-vs-class.html I am not aware if one takes precedence over the other. Are you placing the header ID inside the table with the class 'canvas' by any chance?
Thanks Colleen - I am placing the header ID in the table with the class 'canvas'. Like this - <table id="header" class="canvas"> Code (markup):
I've never seen an ID and CLASS used together, but there's some information about it here. http://codepunk.hardwar.org.uk/acss06.htm
Just a question, why place an ID in a table? You could use <div id="header"> and drop the table tag in whole. And answer to your question id goes over class. Good luck
Yep, I am a little active there. Dave invited me and likes to send those reminders to 'come post' lol.