Mike Wrote:
Every page layout is identical except that the background image for the
content is different. Right now I have in the CSS
(www.jimbarnettconsulting.com/test/jbc.css) #content, #content_about,
#content_jims_team, #content_partners... right now 13 separate IDs and all
of them are identical:
#content {
background: #807060 url(images/welcome.jpg) no-repeat top left;
width: 543px;
margin: 0px 10px 0px 10px;
padding: 45px 10px 0px 10px;
float: left;
}
except the background image. That's a lot of repeated widths, margins,
paddings, and floats.
There must be a way to make one ID of content:
#content {
width: 543px;
margin: 0px 10px 0px 10px;
padding: 45px 10px 0px 10px;
float: left;
}
and then a secondary ID or CLASS for all the pages:
How do I make my CSS less cumbersome?
----------
why do you need to have the image as a background? why not just make it an H1
with an img background and off-screen text?
then you could just do this code:
#content {
width: 543px;
margin: 0px 10px 0px 10px;
padding: 45px 10px 0px 10px;
float: left;
}
#content h1.about {
background: #807060 url(images/about.jpg) no-repeat top left;
}
#content h1.jims_team {
background: #807060 url(images/about.jpg) no-repeat top left;
}
also - i believe that underscores in css id names is not so good. try .jimsTeam
this is my first response, so it may get railed, but i think it is sound.
hopefully others will let you and i know their solutions. i am trying to answer
some css-d list questions, so i know that my own css logic is sound.
cheers,
steff
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
IE7 information -- http://css-discuss.incutio.com/?page=IE7
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/