Using Html Server Controls in your Web Pages

The HTML Server controls are the simple server controls that can be used in the HTML page. These server controls are the ordinary server controls that have a runat=”server” attribute to it. For example an InputText html server control will look like,

<input type=text | password
runat="server" >

In the above code you will find that an InputText html server control has several attributes that can be set during design time using the properties window and they can also be set during runtime programmatically. The runat=”server” attribute indicates that it is a server control.

There are many html server controls that you can use in your web page. Some of the commonly used input html server controls are HtmlInputText, HtmlInputButton, HtmlInputImage, HtmlInputHidden, HtmlInputRadioButton, HtmlInputCheckBox, and HtmlInputFile. Name, Value, and Type are the properties that are shared among these html input server controls. Container controls like HtmlTextArea, and HtmlSelect share properties like InnerHtml and InnerText.

If you are using an IDE like Visual Studio .Net then you can find the html controls grouped in a tab called Html Controls in the Tool palette. You can simply drag and drop the controls in the web page to use them.