HTML Controls


This book has discussed server-side controls at great length. The server-side controls covered so far all derive from System.Web.UI.WebControls. ASP.NET offers another group of controls, though. They fall into the category of HTML controls. HTML controls are simply server-side representations of standard or normal HTML elements. Any HTML element that is contained in ASPX page and is marked with a runat ="server" attribute becomes an HTML control on the server. These controls all derive from HtmlControl class. If you use an HTML element that has functionality that can't be represented with anything that has server-side functionality such as dib or span, it is represented as an HTML generic control instance.

These HTML controls are designed to have direct counterparts to normal HTML instances. This means that you can more easily transfer your classic ASP applications to ASP.NET applications by changing their HTML elements and adding a runat="server" attribute. Then you can simply change the file extension from .ASP to .ASPX. This gives you an ASP.NET page with a complete set of server-side controls.


Special Edition Using ASP. NET
Special Edition Using ASP.Net
ISBN: 0789725606
EAN: 2147483647
Year: 2002
Pages: 233 © 2008-2017.
If you may any questions please contact us: