With Webform Javascript Field you can use custom JavaScript or jQuery snippets for all your Webform form elements.
Features
- Use custom JavaScript code for all webform components.
- Bundle your helper functions in a custom file and load them for the entire webform.
Requirements
Configuration
Edit your Webform components (e.g. node/[nid]/webform/components/[cid]) and add some JavaScript code that should be used in the field JavaScript Snippet. For example you can write a custom formatter and use it to format the input value:
jQuery("input[name='submitted[sphere]']").focusout(function() {
trim_value(this);
format_sph(this);
});
In addition, you can use a custom Javascript file which bundles all of your helper functions. All you have to do is entering the path to your file (e.g. sites/all/libraries/Calculation/js/formatter.js) on the node edit tab. Now you can simply call the desired function on the component edit page like described above.
Credits
The project has been sponsored by @culfin.
Project information
- Minimally maintained
Maintainers monitor issues, but fast responses are not guaranteed. - Maintenance fixes only
Considered feature-complete by its maintainers. - 70 sites report using this module
- Created by aprogs on , updated
- Stable releases for this project are covered by the security advisory policy.
Look for the shield icon below.
Releases
Development version: 7.x-1.x-dev updated 25 Sep 2015 at 09:58 UTC