【发布时间】:2010-10-09 23:50:11
【问题描述】:
我有一个标准的 aspx 页面,我需要在其中添加另一个标准 HTML 表单并将其提交到另一个位置(外部站点),但是每当我按下提交按钮时,页面似乎会回发而不是使用子表单操作 url。
以下形式关系的模型。请注意,在实际部署中,表单将成为母版页布局的内容区域的一部分,因此表单需要独立于母版页表单提交。
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<form id="subscribe_form" method="post" action="https://someothersite.com" name="em_subscribe_form" >
<input type="text" id="field1" name="field1" />
<input id="submitsubform" type="submit" value="Submit" />
</form>
</div>
</form>
</body>
</html>
【问题讨论】: