Reputation: 3611
I am writing HTML to an ASP.NET page (from a web service response), and the HTML has <form>
tags. Unfortunately, because the ASP.NET page already has a wrapped around it, a lot of the buttons on the page break. Does anyone know how I can nest the form inside the ASP.NET page without breaking the top-level form?
Note: the HTML I am bringing in is a form with a bunch of hidden fields inside of it, and it has to be placed within the ASP.NET page, and thus nested in the top-level form.
Thanks
Upvotes: 0
Views: 185
Reputation: 415840
ASP.Net webforms does not allow form tags within it's main runat="server" form. You just can't do it. To work around this, you have three options:
Upvotes: 1
Reputation: 10071
<form>
tags are not allowed to nest inside <form>
tags. Depending on the effect you're interested in, you could put the extra <form>
outside the ASP.Net one, and use absolute positioning to put it where you want in the page.
Upvotes: 0