返回目录
更多资源请访问>>>BK设计资讯站(Www.Blue1000.Com)Www.Blue1000.Com
主要解答:saucer
感谢:ahking
审核者:net_lover
如果涉及到数据库,在下拉选单选中不同值时,文本框的值对应到其他字段值??
-----------------------------------------------------------------------------------------
如果有一个数据库含有名称、单价、数量字段,当Select选择名称时,一个文本框显示单价、一个显示数量,怎么写??
---------------------------------------------------------------
<form>
<select onchange="this.form.quantity=this.options[this.selectedIndex].getAttribute('quantity');this.form.price=this.options[this.selectedIndex].getAttribute('price'); ">
<option quantity="数量" price="单价">名称</option>
</select>
<input name="quantity">
<input name="price">
</form>
返回目录