Click here to Skip to main content
15,891,136 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hii ,

My scenario is like i have login view control on my top of the page which requires form tage with runat=server tag ,

i also need to form tag with runat=server tag for content place holder so that it will be for all child pages ,

Between this there are few search boxes which requires form tags but these are without runat=server attributes/

obviously i cannot use nested for tag by putting after body ..which is not supported .

if i remove all the small form tages and put one single all my design of the form gets messy ..please suggest me something on this
Posted
Updated 22-Oct-14 2:39am
v2

1 solution

ASP.NET does not support multiple form tags with runat="server" - http://msdn.microsoft.com/en-us/magazine/cc163736.aspx#S4[^]...
But, because HTML does support multiple form tags you can have them also in ASP.NET, but only one of them can have runat="server" and for that only one of them will be linked to your Page object on the server...
(Even HTML does support multiple form tags it is not recommended to do so without very good reason - you will get lost very easily on such page...)
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900