This project is not covered by Drupal’s security advisory policy.
Allows HTML5 autocomplete attributes to be set for form input elements to help browsers to autofill them. Speed up prospective form filling times by helping browsers autocomplete your form fields with the correct type of data. Alternatively, disable autofill suggestions if your webform fields contain sensitive information.
Background information & browser support
The Web Hypertext Application Technology Working Group (WHATWG) community has proposed extending the autocomplete attribute in HTML5 to support 'typed' autocomplete fields. You can specify what kind of data a field expects with this attribute, such as 'shipping province' so that users can just use their browser's autofill suggestions rather than manually entering all their data.
Autofill suggestions can be disabled by setting the attribute to 'off', which may be useful for security if a field may contain sensitive information that should not appear in autocomplete suggestions. This is already implemented in most modern browsers.
Chrome has implemented named autocomplete types since 2012 (see original post and subsequent change to use the WHATWG spec), although it will only do so when there are at least 3 fields on a page using the autocomplete attribute.
Internet Explorer uses vCard information to do this in a similar way (and has done since IE5!), instead of using the autocomplete attribute. This module allows this vcard_name attribute to be set too.
Unfortunately, these are currently the only browsers that allow setting hints in this way for their autofilling functionality. For example, other browsers such as Firefox only use surrounding text (e.g. labels) and the ID and name attributes on the input boxes, to determine what autocomplete data to suggest.
Module dependencies
This module currently only implements this functionality for Webform textfield, email and number components in the Form Builder Webform UI, so is currently dependent on those two modules, but could be expanded to work for:
- Webform components without form builder
- Any other webform components that can be autocompleted
- Field widgets with compatible input elements.
Example usage
When editing/adding a textfield, number or email component on a webform in the form builder UI, click the component to edit its details and set the autocomplete type and/or vCard names. Save the form. In Chrome, there needs to be at least 3 fields with an autocomplete type. In Internet Explorer, only the vCard name setting is recognised. See the links above for information on each of those browsers' implementation and lists of their supported attribute values.
View the webform and double-click the fields to see autofill suggestions based on previous forms. If there is no information, it may be that there are no suggestions. Try creating another similar form with at least 3 fields (but potentially with different names/labels) and the same autocomplete types / vCard names, and submitting that with data first - you should then have some suggestions for each of the fields that have an autocomplete type / vCard name.
About the Developers
This project is currently maintained by developers at ComputerMinds - visit us at http://www.computerminds.co.uk. We at ComputerMinds pride ourselves on offering quality Drupal training, Drupal development and Drupal consulting. Go Drupal!
Project information
Minimally maintained
Maintainers monitor issues, but fast responses are not guaranteed.Maintenance fixes only
Considered feature-complete by its maintainers.- Project categories: E-commerce, User engagement, Security
1 site reports using this module
- Created by james.williams on , updated
This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.

