首页 技术 正文
技术 2022年11月21日
0 收藏 959 点赞 3,107 浏览 1146 个字

html 代码部分

<div id="list-name-input" class="list-name-input">
<select type="text" class="list-select" id="list-select">
<option value="">
</option>
<option value="0">
000000
</option>
<option value="1">
111111
</option>
<option value="2">
222222
</option>
</select>
<input type="text" class="name item-width list-name-for-select" id="list-name-for-select">
</div>

CSS 部分代码

 <style type="text/css">
.list-name-input{
color: #333;
font-family: tahoma, 'Microsoft YaHei', 'Segoe UI', Arial, 'Microsoft Yahei', Simsun, sans-serif;
font-size: 15px;
font-weight: bold;
height: 50px;
margin: 0px;
padding: 0px;
position: relative;
width: 530px;
}
.list-name-for-select{
border:;
color: #555;
height: 20px;
lighting-color: rgb(255, 255, 255);
line-height: 20px;
margin:0 0 10px 0;
outline-color: #555;
outline-offset: 0px;
outline-style: none;
outline-width: 0px;
padding: 4px 6px;
position: absolute;
top: 1px;
left: 3px;
vertical-align: middle;
width: 486px;
}
.list-name-input-for-select:focus{
border:;
border-radius:;
}
.list-select{
background-color: #FFF;
border:1px #ccc solid;
border-radius: 4px;
color: #555;
cursor: pointer;
height: 30px;
left: 0px;
margin:0 0 10px 0;
padding: 4px 6px;
position: absolute;
top: 0px;
vertical-align: middle;
white-space: pre;
width: 530px;
}
</style>

效果图

css实现文本框和下拉框结合的案例

css实现文本框和下拉框结合的案例

相关推荐
python开发_常用的python模块及安装方法
adodb:我们领导推荐的数据库连接组件bsddb3:BerkeleyDB的连接组件Cheetah-1.0:我比较喜欢这个版本的cheeta…
日期:2022-11-24 点赞:878 阅读:8,983
Educational Codeforces Round 11 C. Hard Process 二分
C. Hard Process题目连接:http://www.codeforces.com/contest/660/problem/CDes…
日期:2022-11-24 点赞:807 阅读:5,500
下载Ubuntn 17.04 内核源代码
zengkefu@server1:/usr/src$ uname -aLinux server1 4.10.0-19-generic #21…
日期:2022-11-24 点赞:569 阅读:6,344
可用Active Desktop Calendar V7.86 注册码序列号
可用Active Desktop Calendar V7.86 注册码序列号Name: www.greendown.cn Code: &nb…
日期:2022-11-24 点赞:733 阅读:6,127
Android调用系统相机、自定义相机、处理大图片
Android调用系统相机和自定义相机实例本博文主要是介绍了android上使用相机进行拍照并显示的两种方式,并且由于涉及到要把拍到的照片显…
日期:2022-11-24 点赞:512 阅读:7,762
Struts的使用
一、Struts2的获取  Struts的官方网站为:http://struts.apache.org/  下载完Struts2的jar包,…
日期:2022-11-24 点赞:671 阅读:4,838