module
How to add custom javascript into the drupal webform module <form> <submit>
Posted Tue, 12/01/2009 - 2:43pm
Recently, one of our clients asked to have custom tracking code implemented into their form submissions.
Since the client's site is built on Drupal, all forms are dynamically generated using the Webform module.
Their marketing company instructed us to add an 'onclick' code to
<input type="submit" class="form-submit" value="Receive Coupons" id="edit-submit" name="op" onclick=tracking("track_submit_quote") />However, since the Webform module creates all forms dynamically, there was no convenient way of hard coding the code into the form... i.e. there was no way for this to be done via webform admin.