简易自定义下拉菜单 与简易默认下拉html片段

简易自定义下拉选择 html片段

html:

<div class="select_box province">
<div class="selected">T时代C5</div>
<div class="select_list_box" style="display:none;">
<div class="select_list">T时代C5</div>
<div class="select_list">T时代C5</div>
<div class="select_list">T时代C5</div>
<div class="select_list">T时代C5</div>
<div class="select_list">T时代C5</div>
</div>
</div>

css:

 

.select_box{width:208px;height:26px;position:absolute;left:424px;top:80px;cursor:pointer;z-index:6;}
.select_box .selected{width:208px;height:26px;font-size:15px;line-height:26px;text-indent:18px;}
.select_list_box{width:208px;/*height:150px;*//*overflow:hidden;overflow-y:scroll;*/background:#FFF;}
.select_list_box .select_list{width:208px;height:26px;font-size:15px;line-height:26px;text-indent:18px;border-top:1px solid #f5f5f5;}
.select_list_box .select_list:hover{background:#c9c9c9;}

.province{top:205px;z-index:5;}

 

系统默认下拉

html

<div class="select_box">
<select name="listZhiwei1" size="1"></select>
<select name="listZhiwei2" size="1"></select>
<select name="listZhiwei3" size="1"></select>
</div>

 

css

.select_box { width: 490px; position: relative; z-index: 2; }

.select_box select { width: 151px; height: 55px; margin-right: 8px; }

 

郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。