ASP获取JS表单中的值
<scripttype="text/javascript">functionsetid(){str='<br>';if(!window.form1.upcount.val...
<script type="text/javascript">
function setid()
{
str='<br>';
if(!window.form1.upcount.value)
window.form1.upcount.value=1;
if(window.form1.upcount.value>10){
alert("您最多只能增加10个信息");
window.form1.upcount.value = 10;
setid();
}
else{
for(i=1;i<=window.form1.upcount.value;i++)
str+='<div>文件'+i+':<input type="text" name="textfield'+i+'"> <input type="text" name="textfield2'+i+'"> </div><br><br>';
window.upid.innerHTML=str+'<br>';}
}
</script> 展开
function setid()
{
str='<br>';
if(!window.form1.upcount.value)
window.form1.upcount.value=1;
if(window.form1.upcount.value>10){
alert("您最多只能增加10个信息");
window.form1.upcount.value = 10;
setid();
}
else{
for(i=1;i<=window.form1.upcount.value;i++)
str+='<div>文件'+i+':<input type="text" name="textfield'+i+'"> <input type="text" name="textfield2'+i+'"> </div><br><br>';
window.upid.innerHTML=str+'<br>';}
}
</script> 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询