Closed (fixed)
Project:
Webform
Version:
6.x-3.15
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Issue tags:
Reporter:
Created:
12 Sep 2010 at 02:20 UTC
Updated:
25 Mar 2012 at 22:08 UTC
Jump to comment: Most recent file
Comments
Comment #1
quicksketchWe already have an "email" component, so this is probably a trivial change. HEAD is Drupal 7 and DRUPAL-6--3 is for Drupal 6.
Comment #2
quicksketchI should note that the immediate benefit we get from this change is that mobile devices like iPhones and Android phones give you a keyboard suitable for entering e-mail addresses (including the @ sign and .com) when type="email". Versus a text field they present the normal all-purpose keyboard.
Comment #3
daykkin commentedSo what solution we have, to change type="text" with type="email" and etc on drupal 6? It is very needed thing for me.
Comment #4
quicksketchSeems like utilizing http://drupal.org/project/elements would be the best approach to use here, since you can't set #type = 'email' and have it work with Drupal out-of-box. Utilizing Elements might also have the benefit of automatically utilizing its advanced options if the module exists, rather than creating more options within Webform.
Comment #5
quicksketchIn #260708: Number component (Numeric field), we've solved this problem simply by creating a "webform_number" element. This was remarkably simple, and not as much work as I had been anticipating. Considering all input elements already gracefully degrade without an HTML5 shim/shiv, I don't see any reason to depend upon another module for this functionality.
Here are two patches which provide a type="email" element for both D6 and D7.
Comment #6
quicksketchCommitted to both 3.x branches. This'll be in the 3.16 version when it comes out.
Comment #8
carlos.macao commentedThis breaks Compact Forms.
To solve the problem I've patched compact_form.js at line 21 from:
if (!$field.length || !$field.is('input:text,input:password,textarea')) {
to:
if (!$field.length || !$field.is('input:text,input:password,textarea, [type=email], [type=tel], [type=url], [type=number], [type=range], [type=date], [type=time], [type=datetime], [type=datetime-local], [type=month], [type=week], [type=color], [type=search]')) {
Comment #9
Dret commentedHi to all,
I would like to purpose a setting for choosing the markup syntax between HTML5 and XHTML (or HTML 4) for INPUT tag .
At this time, my XHTML theme is invalidated by modification introduced in the last version about:
<strong> input type="email"</strong>Considering I have a webform in all my site pages... ALL my site now appears as an invalid theme code for W3C standard.
In this way only HTML5 themes were supported. It seems to be an extreme choice considering that HTML5 in still in DRAFT!
Thanks!
Comment #10
Isostar commentedI also get a W3C validation error like #9
Comment #11
quicksketch@Dret: See #1375708: Provide a site-wide setting for utilizing HTML5 elements
Let's keep this issue as a feature request closed.