A way to incllude a project estimator on a Webform?

Events happening in the community are now at Drupal community events on www.drupal.org.
Katrina B's picture

Here's a project I haven't yet found a solution for:

Part 1: A JavaScript project estimator.

Examples: http://estimator.astuteo.com/ and http://simplythebest.net/scripts/DHTML_scripts/javascripts/javascript_49...

Part 2: A Webform.

Desired end result: The estimator is tied to (appears on) the Webform. A potential customer uses the estimator to decide what website design/building features he/she wants, then fills out the rest of the Webform with contact information and sends it off. The recipient receives an email with the features chosen and the person's contact information, so the recipient can call/email the potential client to follow up.

I'm stymied as to how to do this in Drupal. Any ideas? Suggestions?

Comments

webform

james.wilson's picture

Webform will get you all the fields and the email notifications. It seems the only thing missing is a way to stick javascript in the form?
Couple possible methods:

Call the javascript from the body (php input format) or load an external javascript file using drupal_add_js() (also from the body).

Create a custom content type for the estimate webform. Add a custom node tpl file in the theme to add in the required javascript.

For me, the second option sounds best. It would be hard to use an existing library to do the estimates, as the form field names would be different. Without writing some custom javascript specific to the form, not sure this is possible.

triadDUG

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

Hot content this week