Use HTML5 to build the next generation Web Form, html5form

Source: Internet
Author: User

Use HTML5 to build the next generation Web Form, html5form

As the most widely used programming language today, the HTML language is easy to use, fast, and compatible with multiple browsing platforms. However, with the development of the times, the HTML standards have stagnated, this time we are still developing [color = #444444! Important] HTML5 standard updates can be said to bring new vitality to this markup language. This article will focus on the Web Forms 2.0 in HTML5, that is, the form section.
Forms are common controls (sets) in Web pages ). From website registration and logon to enterprise data management systems, there are basically forms. Form is so important because it undertakes a large number of tasks of updating and interacting with webpage Background Data. Web developers can say they love and hate Web forms. What they love is its convenient function of collecting and organizing data, what it hates is that its functions are simply the same to a large extent. Some functions that seem common to end users, such as input type check, form verification, and error prompt, developers all need to spend a lot of energy using JavaScript and DOM programming to meet these naturally needed functional points. With the popularity of Ajax, some JavaScript tool libraries, such as Dojo, YUI provides convenient JavaScript widgets or APIs to ease the burden on developers.

New HTML5 Form Features
HTML5 Web Forms 2.0 is a comprehensive enhancement to the current Web Forms. It maintains simple and easy-to-use features while adding many built-in controls or control attributes to meet users' needs, it also reduces developers' programming. In my opinion, HTML5 mainly improves the current Web forms in the following aspects:
1. New Control Type
◆ Are you still worried about the type check? Are you still worried about the long string of regular expressions that you cannot understand, HTML5 provides a series of new controls that provide the type check function. For example, the URL input box and Email input box.



<LI class = "alt"><InputType = "url"> </<SPAN> input>

  • <InputType = "email"></<SPAN>Input>


◆ Of course, there are also very important date input boxes. You must know that it takes a lot of effort to "manually" Create A Date input box using JavaScript and CSS, similar to Dojo, class libraries such as YUI are also widely written on this widget.



  • <InputType = "date"> </<SPAN> input>


◆ As part of my painful memories, I often remember that our developers should dynamically add many options for a select drop-down table. Most of these options come from the database, for example, the list of countries, provinces, and cities. This is very complicated. HTML5 supports the data attribute, which is the select Control's external data source!

Http://html5.662p.com/thread-43-1-1.html


Question about html5 form labels?

Well, this is a new feature of html5. Before that, the elements in a form can only be written in the form tag. html5 allows the elements to be written outside the form tag. You only need to use the form attribute of the input element to point to the form.
Therefore, the first user_form in your Code assigns an id to the form, and the second user_form indicates that the input belongs to the form whose id is user_form.

What do I need to learn to develop web applications using html5?

At present, many things are html, But browser support is not very good. If you use html5 + css3 + javascript + background language, you can skip this background language if you do not need it. You can use php, jsp, asp, and asp.net to directly perform page interaction. You can use other interfaces, such as C, c ++, vb, c #, and python, to perform Socket interaction.

Related Article

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.