<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Expires" CONTENT="0">
<meta http-equiv="Cache-Control" CONTENT="no-cache">
<meta http-equiv="Pragma" CONTENT="no-cache">
<title>上传文件</title>
</head>
<body topmargin="0" leftmargin="0">
<div align="center">
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<form name="form_upload" method="post" enctype="multipart/form-data" action="ht_SaveUpload.jsp">
<tr>
<td>
<table width="100%" border="1" cellpadding="0" cellspacing="0" id="mainTable">
<tr>
<td width="40%" height="25" align="center">图片数量:</td>
<td width="69%" align="left">
<select name="imageNum" size="1" id="imageNum" οnchange="addTable(this.value)">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
</select></td>
</tr>
<tr>
<td height="25" align="center">图片路径:</td>
<td align="left">
<input name="imageFile" type="file" size="30" /></td>
</tr>
</table>
</td>
</tr>
<tr>
<td height="25" colspan="2" align="center"><input type="submit" name="Submit" value="上 传" />
<input name="reset" type="reset" id="reset" value="取 消" /></td>
</tr>
</form>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0" id="templeteTasble" style="display:">
<tr>
<td height="25" align="center">图片路径:</td>
<td align="left">
<input name="imageFile" type="file" size="30" /></td>
</tr>
</table>
<script language="javascript">
<!--
function addTable(obj,imageNum,colNum,rowNum){
var tempObj = eval("document.all." + obj );
var intTBodyCount = tempObj.rows.length;
var intCount = intTBodyCount-imageNum-1;
if(intCount > 0)
{
for(var i = 0;i < intCount;i++)
{
tempObj.deleteRow(tempObj.rows.length-1);
}
}
else
{
intCount = -intCount;
for(var i = 0;i < intCount;i++){
newline = tempObj.insertRow();
for(var j = 0; j < colNum; j++ ){
var tabTd = newline.insertCell();
//复制属性
tabTd.mergeAttributes(tempObj.rows[rowNum].cells[j]);
tabTd.innerHTML=tempObj.rows[rowNum].cells[j].innerHTML;
}
}
}
}
//-->
</script>
</div>
</body>
</html>