<script language="javascript">
function del()
{
document.all.s1.remove(document.all.partUser.selectedIndex);
}
</script>
<select name="s1">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
</select>
<input type="button" onclick="del()" value="delOption">
function del()
{
document.all.s1.remove(document.all.partUser.selectedIndex);
}
</script>
<select name="s1">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
</select>
<input type="button" onclick="del()" value="delOption">
解决方案 »
- DIV样式调节
- jquery 表格弄出来的东西塞进数组?
- 怎样在框架链接里实现按当前日期自动改写链接地址
- 求这样一个时间选择联动效果~~
- JQuery easyui tabs.有个的需求,求帮助!!!
- 怎样获取mediaplayer或者realplayer object的状态
- (第二次提问)<!--想在iframe里显示纯文本,内附完整代码,请大家帮忙!-->
- 怎样从动态生成的表单组件<type=text>中读出value的值
- 高手请进,请问如何把要投票选定的产品的值传递到相应的文本框中。
- jquery tabs 选项卡 ,在浏览器中,点击选项卡后URL没变化
- 如何延迟?
- 双击鼠标后滚动屏幕的问题 :)
增加一個節點是:
o=document.createElement("OPTION");
o.text=""
o.value=""
document.all.s1.add(o);
function del()
{
with(document.all.s1)if(selectedIndex>=0)options[selectedIndex].removeNode(true);
}
</script>
<select name="s1">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
</select>
<input type="button" onclick="del()" value="delOption">