点击这个添加更多动态复制上面的div中的table里面的控件 后台可以获取到每个table中标签的id 或者直接可以获取 多个table中控件上的数据
我是asp的新手不清楚这个 这个服务器的控件的js代码怎么写 或者可以直接在控件的添加更多事件里面实现
<div id="divtable">
<table class="add_table" id="table" width="100%">
<tr>
<td width="90">产品编号</td>
<td>
<asp:TextBox ID="product_no" runat="server" TextMode="Number"></asp:TextBox>
<asp:RequiredFieldValidator ID="reg_no" runat="server" ErrorMessage="✘请输入编号" ControlToValidate="product_no" ForeColor="Black"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td width="90" class="auto-style1">产品名称</td>
<td class="auto-style1">
<asp:TextBox ID="product_name" runat="server"></asp:TextBox>
<asp:RequiredFieldValidator ID="reg_name" runat="server" ErrorMessage="✘请输入名称" ControlToValidate="product_name"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td width="90">产品价格</td>
<td>
<asp:TextBox ID="product_price" runat="server" TextMode="Number"></asp:TextBox>
<asp:RequiredFieldValidator ID="reg_price" runat="server" ErrorMessage="✘请输入价格" ControlToValidate="product_price"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td width="90">产品型号</td>
<td>
<asp:TextBox ID="product_model" runat="server"></asp:TextBox><asp:RequiredFieldValidator ID="reg_mod" runat="server" ErrorMessage="✘请输入型号" ControlToValidate="product_model" Width="100px"></asp:RequiredFieldValidator>
<asp:FileUpload ID="selectfile" runat="server" ToolTip="请选择文件" />
</td>
</tr>
<tr>
<td width="90">产品描述</td>
<td>
<asp:TextBox ID="product_introduce" runat="server" Width="524px" TextMode="MultiLine" Height="24px"></asp:TextBox>
</td>
</tr>
</table>
<div align="center">
<asp:Button ID="addmore" runat="server" Text="↓添加更多" OnClick="addmore()" />
<br />
<br />
<asp:Button ID="btnDo" runat="server" Text="执行操作" OnClick="btnDo_Click" />
</div>
</div>
</asp:Content>