【HTML5】input类型

* email

<input type="email" name="user_email" />

* url

<input type="url" name="user_url" />

* number

<input type="number" name="points" min="1" max="10" />

* range

<input type="range" name="points" min="1" max="10" />
属性描述
max number 规定允许的最大值
min number 规定允许的最小值
step number 规定合法的数字间隔(如果 step="3",则合法的数是 -3,0,3,6 等)
value number 规定默认值

* data

<input type="date" name="user_date" />

HTML5 拥有多个可供选取日期和时间的新输入类型:

  • date - 选取日、月、年
  • month - 选取月、年
  • week - 选取周和年
  • time - 选取时间(小时和分钟)
  • datetime - 选取时间、日、月、年(UTC 时间)
  • datetime-local - 选取时间、日、月、年(本地时间)
原文地址:https://www.cnblogs.com/anni-qianqian/p/5585571.html