#885 new
dleffler

Feature request - Add new html5 input types

Reported by dleffler | January 25th, 2013 @ 02:22 AM | in 2.2.0beta3 (closed)

There are several new input types allowed by html5 that aid form completion, esp. on handheld devices. The drawback is that they are not all fully implemented in each browser, however there are some fallback options http://diveintohtml5.info/forms.html, and at the very least, they fallback to a straight text input control.

This might best be implemented as a variation of the textcontrol (or genericcontrol) and isolated via the {control} smarty function. Here's a site with charts showing browser features: http://caniuse.com/forms

html5 controls worth adding would be:

  • we've already implemented 'placeholder' attribute but have no fallback
  • email
  • url
  • tel, telephone
  • number, as a spinbox with min, max, step, & value
  • range, number as a slider with min, max, step, & value
  • fieldset, probably needs to be reserved for wizard/pages?
  • maxlength, attribute for textarea (we already do input maxlength)
  • accept, attribute to limit filetype/mimetype of file input?

html5 control featurs not worth adding?

  • date, datetime, datetime-local, month, week, & time, date pickers aren't supported very well in browsers and we have a 'fallback' controll already
  • search, only provides a rounded box?
  • color, again not supported well and we already have a 'fallback' control
  • list, kinda like autocomplete is not supported well and we have one for tags already
  • autofocus, attribute though it has an easy fallback, we may not be on that control's tab?

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Bug Tracker for Exponent CMS

Shared Ticket Bins

People watching this ticket

Pages