It doesn't remove everything inside the 2nd form tag but just hides the and tags from the page
Any ideas and workaround?
It doesn't remove everything inside the 2nd form tag but just hides the and tags from the page
Any ideas and workaround?
The reason ASP.NET encloses everything in a single form is so that when a postback occurs, the whole form is posted back to the server and you will have access over every element that is on the page.
That is you are able to modify the properties of elements (myTextbox.Text = 'Hello';
) from the Code-Behind.
You cant have nested form tags. Either move to asp.net mvc if you want more control over the markup or consider not using asp.net server controls, this way you can include multiple form tags without having to ensure the controls are within a form tag with the runat server attribute but then you dont get the granular access in the code behind and have to start using the request.form colelction to retrieve the postback values.