DropdownList自定义样式(二)
Combox.css文件代码如下:
Code
.DrpBox_normal
{
background:url(/images/folder/bg_input.gif) repeat-x bottom; /*图片路径可以自定义*/
background-color:#ffffff;
height:22px;
line-height:22px;
border:1px solid #afdae6;
margin-left:2px;
color:#4d4b4b;
overflow:hidden;
}
.DrpBox_focus
{
background:url(/images/folder/bg_input.gif) repeat-x bottom; /*图片路径可以自定义*/
background-color:#ffffff;
height:20px;
line-height:20px;
border:1px solid #afdae6;
border-left:4px solid #33cc00;
color:#4d4b4b;
overflow:hidden;
}
.DrpBtn
{
width:20px;
height:22px;
line-height:22px;
float:left;
background-image:url(/images/folder/ico_drp_btn.gif); /*图片路径可以自定义*/
background-repeat:no-repeat;
background-position:center;
}
.DrpOptionsBox
{
margin-left:2px;
border:solid 1px #afdae6;
position:absolute;
background-color:White;
clear:both;
height:22px;
line-height:22px;
}
.DrpOptions
{
text-indent:2px;
height:22px;
line-height:22px;
clear:both;
overflow:hidden;
clear:both;
}
.DrpOptionsSeled
{
text-indent:2px;
background-color:#afdae6;
height:22px;
line-height:22px;
clear:both;
}
.DrpOptionsOver
{
text-indent:2px;
background-color:#d7ecf2;
height:22px;
line-height:22px;
clear:both;
}
.sDrpBox_normal
{
margin-left:2px;
background-color:#ffffff;
height:22px;
line-height:22px;
border:1px solid #afdae6;
border-left:1px solid #afdae6;
color:#4d4b4b;
overflow:hidden;
}
.DrpInput_normal
{
text-indent:4px;
background-color:#ffffff;
height:22px;
line-height:22px;
color:#4d4b4b;
overflow:hidden;
float:left;
}
.DrpBox_normal
{
background:url(/images/folder/bg_input.gif) repeat-x bottom; /*图片路径可以自定义*/
background-color:#ffffff;
height:22px;
line-height:22px;
border:1px solid #afdae6;
margin-left:2px;
color:#4d4b4b;
overflow:hidden;
}
.DrpBox_focus
{
background:url(/images/folder/bg_input.gif) repeat-x bottom; /*图片路径可以自定义*/
background-color:#ffffff;
height:20px;
line-height:20px;
border:1px solid #afdae6;
border-left:4px solid #33cc00;
color:#4d4b4b;
overflow:hidden;
}
.DrpBtn
{
width:20px;
height:22px;
line-height:22px;
float:left;
background-image:url(/images/folder/ico_drp_btn.gif); /*图片路径可以自定义*/
background-repeat:no-repeat;
background-position:center;
}
.DrpOptionsBox
{
margin-left:2px;
border:solid 1px #afdae6;
position:absolute;
background-color:White;
clear:both;
height:22px;
line-height:22px;
}
.DrpOptions
{
text-indent:2px;
height:22px;
line-height:22px;
clear:both;
overflow:hidden;
clear:both;
}
.DrpOptionsSeled
{
text-indent:2px;
background-color:#afdae6;
height:22px;
line-height:22px;
clear:both;
}
.DrpOptionsOver
{
text-indent:2px;
background-color:#d7ecf2;
height:22px;
line-height:22px;
clear:both;
}
.sDrpBox_normal
{
margin-left:2px;
background-color:#ffffff;
height:22px;
line-height:22px;
border:1px solid #afdae6;
border-left:1px solid #afdae6;
color:#4d4b4b;
overflow:hidden;
}
.DrpInput_normal
{
text-indent:4px;
background-color:#ffffff;
height:22px;
line-height:22px;
color:#4d4b4b;
overflow:hidden;
float:left;
}
用到的两个图片: