Using the HTML5 input type to promote the mobile input experience (keyboard)
Source: Internet
Author: User
<span id="Label3"></p><p><p>In recent projects, planning is always asking us to pop up various types of keyboards, especially under ios, such as entering an account, should not support the input of chinese, the input of pure numbers should talk about the numeric keypad.<br>Personally feel that these are our usual development is seldom aware of, although some tricky, but are for the user experience, for our products, so we found some information on the internet, here with friends to Share:<br><br>Over the past few years, browsing the web on mobile devices has become incredibly popular. however, The browsing experience on these devices is sometimes left with a lot to be desired. This is especially noticeable when it comes to filling out a form. fortunately, The HTML5 specification introduces many new input types, making it easier for users to fill out your Web Forms on mobile Devices.<br>This is a pretty good move, and mobile browser vendors pick up the new HTML5 input type and use them to display customized keyboard layouts that make it easier for users to enter Data.<br>In this article, you will learn about 8 new input types that have been introduced in HTML5.<br>Note: in this article, The iOS screen is intercepted using IPhone5 and Safari. The Android screen is run on the virtual device Android4.1 and its available web browser Intercepts.<br><br></p></p>E-mail input type<p><p></p></p><br>Keyboard for IOS (left) and Android (right) e-mail input<br>Email type, both iOS and Android browsers display a lightly customized Keyboard. Note the shortened space bar exists and the bottom line of the iOS keyboard is joined by the @ and period (.) keys. On android, the standard comma key will appear on the left side of the space bar, which has been replaced by an @ key.<br><input type= "email" name= "email" ><br><br>URL input type<p><p></p></p><br>iOS URL input keyboard<br>The URL input type can be used to help users enter Urls. On ios, all the SPACEBAR has been replaced with a period (.) key and a forward slash (/) key, as well as a special. com key.<br>My test shows that the Android keyboard has not changed.<br><input type= "url" name= "url" ><br><br>Phone number input type<p><p></p></p><br>Keyboard for IOS (left) and Android (right) phone input<br>When using the Tel input type, both iOS and Android are prompted to display the dial pad instead of the standard Keyboard.<br><input type= "tel" name= "tel" > Digital input type<p><p></p></p><p><p>Keyboard for IOS (left) and digital input for Android (right)<br>The number input type prompts iOS to display numbers and punctuation on the Keyboard. The Android browser launches a keyboard similar to the one that displays phone Input.<br><input type= "number" name= "number" ><br><br></p></p>Date input type<p><p></p></p><p><p>iOS date picker<br>There are also many input types available for the date and Time. Because they guarantee that your data is provided in a standard format, these can be very useful.<br>The date input type on iOS prompts you to display a day Selector. unfortunately, The Android browser does not yet support any of the DateTime input Types.<br><input type= "date" name= "date" ><br><br></p></p>Time input type<p><p></p></p><p><p>iOS Time Picker<br>Using the time type prompts iOS to display a simple picker to select hours and Minutes.<br><input type= "time" name= "time" ><br><br></p></p>Date and time input type<p><p></p></p><br>iOS Date Time picker<br>When you use a datetime type, a picker is displayed to select both the date and Time.<br>Although there is no option to select the year explicitly, the picker automatically adds the year to your input based on the date and month that you select.<br><input type= "datetime" name= "datetime" ><br><br>Month input type<p><p></p></p>IOS Month Picker<br>A simplified version of the date selector is displayed when the month Type.<br>The HTML specification also defines a week input type, which, however, does not seem to be implemented on the browser I have Tested.<br><input type= "month" name= "month" ><br><br>browser compatibility for the input type of HTML5<br>Browsers that do not support these new input types will only display a simple text input to the User. This means that you can go ahead and start using these new input types today!<br>In desktop browsers, browsers that support the Date/time input type are still very limited. The Opera browser currently has the best implementations and supports all the types mentioned in this Article. Google's Chrome Browser supports the date type, but now There's nothing else. The Safari browser has a date formatted text field, but does not support calendar widgets like those shown on opera and Chrome.<br><br>fortunately, the days of the browser that once endured a bad experience, on the mobile side have soon Ceased. The benefits of the new mobile-friendly features introduced by HTML5 are sure to enjoy a pleasant experience for all of our users, no matter which device they use.<br><br><p><p></p></p>Useful Links<p><p></p></p><p><p></p></p><p><p>Browser support Date/time input</p></p><p><p></p></p><p><p>Web hypertext Application Technology Working Group HTML5 specification: input type</p></p><p><p></p></p><p><p></p></p><p><p>This article was reproduced from: http://www.oschina.net/translate/using-html5-input-types-to-enhance-the-mobile-browsing-experience?cmp</p></p><p><p> Using the HTML5 input type to promote the mobile input experience (keyboard) </p> </p></span>
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