Forum Moderators: not2easy
layout.css:
/* ----------container to center the layout---------- */
#container {
width: 830px;
padding:0px;
margin: 0px;
margin-left: auto;
margin-right: auto;
}
/*-----------content next to menu------------*/
.boxContent {
border-top: 4px solid #CDB5CD;
border-right: 4px solid #CDB5CD;
border-bottom: 4px solid #CDB5CD;
border-left: 4px solid #CDB5CD;
padding: 3px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 75%;
color: #474785;
margin-bottom: 5px;
background-color: #F2EBF2;
}
.catboxcontent {
border-top: 4px solid #CDB5CD;
border-right: 4px solid #CDB5CD;
border-bottom: 4px solid #CDB5CD;
border-left: 4px solid #CDB5CD;
background-color: #F2F2F2;
padding-left: 11px;
padding-right: 7px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 75%;
color: #474785;
position: relative;
margin-bottom: 5px;
}
/* =-=-=-=-=-=-=-[Menu Six]-=-=-=-=-=-=-=- */
#menu6 {
width: 130px;
margin-left: 17px;
margin-top: 15px;
margin-bottom: 0px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 87%;
font-weight: bold;
}
#menu6 ul {
list-style: none;
margin: 0;
padding-top: 10px;
padding: 0;
}
#menu6 li a {
height: 35px;
voice-family: "\"}\"";
voice-family: inherit;
height: 27px;
text-decoration: none;
}
#menu6 li a:link, #menu6 li a:visited {
color: #683A5E;
text-align: left;
display: block;
background: url(http://www.example.com/skins/Killer/styleImages/csstab1.jpg);
padding: 8px 0 0 10px;
}
#menu6 li a:hover, #menu6 li a:active {
color: #6C7250;
background: url(http://www.example.com/skins/Killer/styleImages/csstab2.jpg);
padding: 8px 0 0 10px;
}
index.tpl:
<div id="container" >
<div id="banner" ><a href="http://www.example.com"><img src="http://example.com/skins/Killer/styleImages/backgrounds/topHeader.gif" alt="" width="830" height="100" border="0px" /></a>
<h1>{CATEGORIE}</h1>
</div>
<div id="pageSurround">
<div id="subSurround">
<br>
<table border="0" cellspacing="0" width="830px" cellpadding="0">
<tr valign="top">
<td width="175">
{SHOPPING_CART}
<div id="menu6">
<ul>
<li><a href="http://example.com/index.php" title="Home">Home</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=2" title="Necklaces">Necklaces</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=3" title="Earrings">Earrings</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=4" title="Bracelets">Bracelets</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=saleItems" title="Sale Items">Sale Items</a></li>
<li><a href="http://example.com/index.php?act=viewDoc&docId=9" title="Materials">Materials</a></li>
<li><a href="index.php?act=viewDoc&docId=2" title="Contact Us">Contact Us</a></li>
<li><a href="index.php?act=viewDoc&docId=3" title="Policies">Policies</a></li>
<li><a href="index.php?act=viewDoc&docId=4" title="Shipping">Shipping</a></li>
<li><a href="index.php?act=viewDoc&docId=6" title="Links">Links</a></li>
</ul>
</div>
{MAIL_LISTS}
<br>
{SEARCH_FORM}
{CURRENC}
{RANDOM_PROD}
{POPULAR_PRODUCTS}
</td>
<td style="padding: 0px 0px 0px 25px;">{PAGE_CONTENT}</td>
</tr>
</table>
</div>
I have changed my CSS code so that the menu looks halfway decent in IE (most of my visitors use IE), but the edges of the images are still cut off and the menu doesn't display correctly in Firefox and Safari.
layout.css:
/* =-=-=-=-=-=-=-[Menu Six]-=-=-=-=-=-=-=- */
#menu6 {
width: 175px;
margin-left: -7px;
margin-top: 15px;
margin-bottom: 0px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 87%;
font-weight: bold;
background-repeat: no-repeat;
}
#menu6 ul {
list-style: none;
margin: 0;
padding-top: 10px;
padding: 0;
}
#menu6 li a {
height: 35px;
voice-family: "\"}\"";
voice-family: inherit;
height: 27px;
text-decoration: none;
}
#menu6 li a:link, #menu6 li a:visited {
color: #683A5E;
text-align: left;
display: block;
background: url(http://www.example.com/skins/Killer/styleImages/csstab1.gif) -15px;
padding: 8px 0 0 10px;
}
#menu6 li a:hover, #menu6 li a:active {
color: #6C7250;
background: url(http://www.example.com/skins/Killer/styleImages/csstab2.gif) -15px;
padding: 8px 0 0 10px;
}
[edited by: encyclo at 2:14 am (utc) on June 20, 2007]
[edit reason] See Guide to Posting Code [webmasterworld.com] [/edit]
what are the dimensions of the tab image?
and what Docytype [webmasterworld.com], if any, do you have at the top of your pages?
My site is based on CubeCart, and I have made changes to both the appearance and functionality of the site in the past. I'm attempting to change the appearance of my site again. However, alignment troubles have always been an issue with IE when altering the CSS and index.tpl code.
#menu6 {
width: 175px;
margin-left: 0px;
margin-top: 15px;
margin-bottom: 0px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 87%;
font-weight: bold;
}
#IEroot #menu6 {
width: 175px;
margin-left: -7px;
margin-top: 15px;
margin-bottom: 0px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 87%;
font-weight: bold;
background-repeat: no-repeat;
}
<!--[if IE]>
<div id="IEroot">
<![endif]-->
<div id="menu6">
<ul>
<li><a href="http://example.com/index.php" title="Home">Home</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=2" title="Necklaces">Necklaces</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=3" title="Earrings">Earrings</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=4" title="Bracelets">Bracelets</a></li>
<li><a href="http://example.com/index.php?act=viewCat&catId=saleItems" title="Sale Items">Sale Items</a></li>
<li><a href="http://example.com/index.php?act=viewDoc&docId=9" title="Materials">Materials</a></li>
<li><a href="index.php?act=viewDoc&docId=2" title="Contact Us">Contact Us</a></li>
<li><a href="index.php?act=viewDoc&docId=3" title="Policies">Policies</a></li>
<li><a href="index.php?act=viewDoc&docId=4" title="Shipping">Shipping</a></li>
<li><a href="index.php?act=viewDoc&docId=6" title="Links">Links</a></li>
</ul>
</div>
<!--[if IE]>
</div>
<![endif]-->