Using the input Element to Restrict Data Entry - HTML CSS HTML Tag

HTML CSS examples for HTML Tag:input

Introduction

Restricted Data type Values

Type DescriptionNew in HTML5
checkbox Restricts the input to a true/false check box. No
color Restricts the input to a color.Yes
date Restricts the input to a date. Yes
datetime Restricts the input to a global date and time with time zone. Yes
datetime-localRestricts the input to a global date and time without time zone. Yes
email Restricts the input to a properly formatted e-mail address.Yes
month Restricts the input to a year and month. Yes
numberRestricts the input to an integer or floating-point number.Yes
radiobutton Restricts the input to a fixed set of choices. No
range Restricts the input to a specified range. Yes
tel Restricts the input to a properly formatted telephone number. Yes
time Restricts the input to a time of day. Yes
week Restricts the input to a year and week.Yes
url Restricts the input to a fully qualified URL. Yes

Demo Code

ResultView the demo in separate window

<html>
   <head></head>
   <body></body>
</html><!--from  w w w. jav  a  2s.  c  o  m-->

Related Tutorials