鄙人写的select值存到input中出来点问题,跪等各位大侠帮忙解答。代码如下 htmlcssphpjsjq 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 用jquery ,select加上onchange事件 <select name="select" onchange="$('input').val($('select option:selected').val())";这样就有值了 <select name="select" style="position:absolute;margin:-10px 0 0 -10px;width:110px;height:20px; clip:rect(0 120 24 100)" id="select" onchange="document.getElementsByName('seo_comment[]')[0].value=select.value;document.getElementsByName('seo_comment[]')[0].select()"> <option value="aaa">aaa</option> <option value="bbb">bbb</option> <option value="ccc">ccc</option> </select> <script type="text/javascript"> function change(){ document.getElementById('txt').value = document.getElementById('select').value; } </script> <select name="select" style="position:absolute;margin:-10px 0 0 -10px;width:110px;height:20px; clip:rect(0 120 24 100)" id="select" onchange="change()"> <option value="aaa">aaa</option> <option value="bbb">bbb</option> <option value="ccc">ccc</option> </select> <input type="text" style="position:absolute;margin:-10px 0 0 -10px;width:88px;height:16px" name="seo_comment[]" id="txt" value=""> phpexcel中如何设置单元格自动换行?? RSS的XML结构都是统一的吗? 前辈,帮解决下这个问题 php即时聊天实现方案 刚刚发现的一个问题 问1个关于JS的问题 请指导下 逻辑问题。。。。虽测试通过。。。请指导。。。。。 寻找国内外PHP产品! 一个WEB查分系统(300分) 哪位帮忙看下这个分页类怎么调用,我说的是在查询语句下 最佳PHP学习路线 防止一些常见的广告发帖,有什么方法?
<select name="select" onchange="$('input').val($('select option:selected').val())";
这样就有值了
<option value="aaa">aaa</option>
<option value="bbb">bbb</option>
<option value="ccc">ccc</option>
</select>
<script type="text/javascript">
function change(){
document.getElementById('txt').value = document.getElementById('select').value;
}
</script> <select name="select" style="position:absolute;margin:-10px 0 0 -10px;width:110px;height:20px; clip:rect(0 120 24 100)" id="select" onchange="change()">
<option value="aaa">aaa</option>
<option value="bbb">bbb</option>
<option value="ccc">ccc</option>
</select>
<input type="text" style="position:absolute;margin:-10px 0 0 -10px;width:88px;height:16px" name="seo_comment[]" id="txt" value="">