Chapter 5. Working with the Page

Although formless pages are still accepted and correctly handled, the typical ASP.NET page contains a single <form> tag decorated with the runat attribute set to server. On the server, the <form> tag is mapped to an instance of the HtmlForm class. The HtmlForm class acts as the outermost container of all server controls and wraps them in an HTML <form> element when the page is rendered. The obtained HTML form posts to the same page URL and for this reason is said to be reentrant. The default method used to submit form data is POST, but GET can be used as well.

In most cases, the server form is the outermost ...

Get Programming Microsoft® ASP.NET 2.0 Core Reference, 2nd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.