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