如何调整.TopMenuItem的宽度,而不是让它们拉伸到适合100%的窗口宽度?我将.TopMenuGroup宽度更改为100%,以便绿色背景拉伸总宽度。
http://themusicshop.com/aeRntplan.aspx
这是我的CSS:
.TopMenuGroup
{
border: solid 0px #003167;
background-color: #005E20;
padding-bottom: 5px;
padding-top: 5px;
width: auto;
}
.MenuGroup
{
border: solid 0px #003167;
background-color: #005E20;
color: #000000;
font-size: 11px;
}
.MenuGroup td {
color: #FFFFFF;
font-size: 11px;
}
.MenuGroupHover td {
color: #FFFFFF;
}
.MenuItemHover td {
color: #99FF33;
}
td.MenuItemHover {
color: #99FF33;
font-size: 11px;
}
.TopMenuItem
{
color: #FFFFFF;
font-size: 12px;
font-weight: normal;
cursor: hand;
cursor: pointer;
font-family: helvetica, arial, sans-serif;
padding-left: 0px;
padding-right: 0px;
}
.TopMenuItemHover
{
color: #99FF33;
background-color: #005E20;
font-size: 12px;
font-weight: normal;
cursor: hand;
cursor: pointer;
font-family: helvetica, arial, sans-serif;
}
-- leaf menu items
.MenuItem
{
background-color:#EEEEEE;
color:#FFFFFF;
font-size:11px;
border: solid 0px white;
cursor:hand;
cursor:pointer;
padding-top: 3px;
padding-bottom: 3px;
}
.MenuItemHover
{
background-color: #005E20;
color: #79FF00;
font-size: 11px;
border: solid 0px white;
cursor: hand;
cursor: pointer;
padding-top: 3px;
padding-bottom: 3px;
}
-- group menu items
.MenuItem td
{
color:#FFFFFF;
font-size:11px;
border: solid 0px white;
cursor:hand;
cursor:pointer;
padding-top: 3px;
padding-bottom: 3px;
}
.MenuItemHover td
{
background-color:#FEDF15;
color:#000000;
font-size:11px;
border: solid 0px white;
cursor:hand;
cursor:pointer;
padding-top: 3px;
padding-bottom: 3px;
}
答案 0 :(得分:1)