Hi guys,
I have 2 divs within a wrap to create my menu box.
Div 1= MenuBoxHeader
Div 2= MenuBoxContent
I have an H2 Tag that has a background image attached to it which I place in Div 1 to make my header.
I have multiple menu boxes on my site, and I want to place different icons in some of those headers.
Code:h2 { background-image: url(img/tab.gif); background-repeat: none; font-size:16px; font-weight:200; height:auto; color:white; font-family:Helvetica; } #menuboxheader { background:none; height:auto; text-align:center; line-height:25px; width:auto; color:white; margin-left:10px; margin-top:15px; float:left; } .menuboxcontent { background:#140324; margin-top:1px; height:263px; text-align:center; width:185px; color:black; font-size:14px; }
I want to place an image next to the H2 tag, which already has an image defined as its background.Code:<div id="menuboxheader"> <h2>Title Here</h2> <div class="menuboxcontent"> </div> </div>
I placed this code in but had to use negative margins to get it to align beside the h2 tag text.
How can I do this without using negative margins to align it up as it seems messy.Code:.menuboxTwitterIcon{ background:url(img/twitter.jpg) no-repeat scroll 0 0; margin-top:1px; height:500px; text-align:center; width:50px; color:black; font-size:14px; margin-left:15px; margin-top:-10px; <div id="menuboxheader"> <h2>Rakeback</h2> <div class="menuboxTwitterIcon"> </div> <div class="menuboxcontent"> </div> </div>
Been doing a lot of trial and error and cannot figure it out!



Reply With Quote





Bookmarks