By Infinity Mark on
Hello All!
I am having a problem stylizing the background image for various node types. I was HOPING that I could simply put a different background image for each similar to this:
div .node-type-bio #main-innner
{
margin-left: 5px;
margin-top: 5px;
background-image: url(/sites/all/themes/tcc/images/bg_page_main_bio.jpg);
background-repeat: no-repeat;
}
But apparently #main-inner is seen before .node-type-bio so the image isn't applied. I want to apply a background image that spans the entire top of the page - main region rather than simply having to slice three images -- one for sidebar-left, content, and side-bar right. Is this my only option??
Thanks for any help on this!
Comments
Progress - but still confused a bit
Okay - so I have determined that I need a different node-nodetype.tpl.php file for each node type in order to have the ability to stylize each node type differently using CSS. My question now is how do I apply css to each specific css node-type? Wouldn't I simply use the same theme.css file I'm using for my custom theme under sites/all/themes/mytheme?
If so coulldn't I just use the css code above to do this?
I'm just sort of confused on how to apply style settings through css to my new node.tpl.php files.
HELP!
_
It can be difficult to impossible to troubleshoot css without a live link, but you can definitely apply css to node types without creating node.tpl.php files. most themes provide a content type class on the node div, but if your's doesn't, you can always add it. You're best bet is to examine the source with firebug to figure out the css you need.