Differences between Web server controls and HTML controls

Source: Internet
Author: User



These two days are learning ASP , encountered a Web server Controls and HTML control. When I first saw these two controls, I felt very similar.

so I think of the following question: What is the difference between these two controls? Then I saw the HTML server control (plus the runat= "Server" property),

this Web server Controls and HTML server controls are more similar. More silly to divide the unclear, so here to summarize.

One, Web server Controls and HTML the difference between controls

Two, Web server Controls and HTML server Control Differences

HTML server controls are HTML Control plus runat= "Server" attributes are formed.

this way, HTML The control can run on the server side, with loopback capability to maintain the state of the control.

Three, Web server controls so many advantages, why do you have HTML the presence of a server control?

1 , some events, such as press, move, mouse operation and other events, Web server controls do not have these events, this time HTML The control will play its part.

2 , Web server controls consume server resources, have too many page echoes, and must be converted to Xtml control to run, so it is slow to run.

3 , if you only make some static pages, you can use the HTML control, fast reaction.

Since the two exist, there must be a difference, and it certainly has its usefulness. Only in practice can we slowly understand and master the usage between them.



Differences between Web server controls and HTML controls

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.