We are in the process of upgrading our ASP.NET 4 website from XHTML 1.0 to HTML 5. The <form> tag is generated automatically as it is ASP.NET, and it looks like:
<form method="post" action="" id="MainForm">
Almost on all pages of our website we do not have any special button that should lead to an action, so it's OK to have the action attribute empty (action=""). However, every HTML 5 validator tells us that the action attribute should not be empty.
How can we overcome this problem without changing the existing website functionality? Or, maybe, we can live with that and this will never affect such serious things as Google SERP positions, etc...?
<form id="MainForm" runat="server">. Will it be ok to add sayaction="./"to it (can it cause some side effects)? – TecMan Feb 03 '14 at 14:18<form>tag from the masterpage at all as it is almost never used in the 'static' pages! We can place this tag with the correspondingactionattribute manually only on the pages which really require it. Agreed? – TecMan Feb 03 '14 at 15:08