Adding a custom submit handler to a form with a CCK field?
I was thinking maybe a CCK field to tell a form what Salesforce lead "Source" categorization a form should have ought to be able to do double duty as the indicator that "this form should be sent to Salesforce as a lead."
However, that would require a CCK field to be able to add a submit handler that applies to the entire form it is added to, and I'm not sure they can do that.
Indeed, while people are increasingly used to the CCK way, it's clear this functionality should live on the main content type editing screen (where publishing options and some contributed module such as fivestar settings are currently). Then it is quite easy to add hidden form elements and custom submit handlers for the whole form with an implementation of hook_form_alter
Resolution
More like this
- Overriding Field Handlers in Views with your own custom handler | Jake Strawn | himerus
- Submit CCK fields during new user registration
- Drupal Salesforce-integrated Contact Form: Specific Use Case
- Don't try to use last insert ID to get the just-submitted user
- Functions needed to define a new CCK field; Field placement module thoughts


Comments
Post new comment