ASP.NET Web Forms - HTML Server Controls
HTML server controls are HTML tags that are understandable by the server.
HTML Server Controls
HTML elements in ASP.NET files are treated as text by default. To make these elements programmable, you need to add the runat="server" attribute to the HTML element. This attribute indicates that the element will be processed as a server control.
Note:All HTML server controls must be placed inside a <form> tag with the runat="server" attribute!
Note:ASP.NET requires that all HTML elements are correctly closed and correctly nested.
| HTML Server Controls | Description |
|---|---|
| HtmlAnchor | Controls the <a> HTML element |
| HtmlButton | Controls the <button> HTML element |
| HtmlForm | Controls the <form> HTML element |
| HtmlGeneric | Controls other HTML elements not already covered by specific HTML server controls, such as <body>, <div>, <span>, etc. |
| HtmlImage | Controls the <image> HTML element |
| HtmlInputButton | Controls the <input type="button">, <input type="submit">, and <input type="reset"> HTML elements |
| HtmlInputCheckBox | Controls the <input type="checkbox"> HTML element |
| HtmlInputFile | Controls the <input type="file"> HTML element |
| HtmlInputHidden | Controls the <input type="hidden"> HTML element |
| HtmlInputImage | Controls the <input type="image"> HTML element |
| HtmlInputRadioButton | Controls the <input type="radio"> HTML element |
| HtmlInputText | Controls the <input type="text"> and <input type="password"> HTML elements |
| HtmlSelect | Controls the <select> HTML element |
| HtmlTable | Controls the <table> HTML element |
| HtmlTableCell | Controls the <td> and <th> HTML elements |
| HtmlTableRow | Controls the <tr> HTML element |
| HtmlTextArea | Controls the <textarea> HTML element |
Other Extensions