Summary

The focus of this chapter was on creating HTML5 forms for Windows Store apps. In the first section, I explained how you can take advantage of the new form validation features included in HTML5. You learned how to use the required and pattern attributes to perform basic validation and the setCustomValidity() method to perform advanced validation.

Next, I described how you can take advantage of the new HTML5 input types. You learned how to accept numbers by using the number and range types. You also learned how to accept email addresses, URLs, telephone numbers, and search terms. I also demonstrated how you can select files from your computer hard drive by using <input type="file" />.

Finally, I demonstrated how you can create a rich text ...

Get Windows® 8.1 Apps with HTML5 and JavaScript Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.