In the mailchimp_signup module, the form that submits and saves the subscriber submission doesn't actually save the results to form_state. What I have is a block version of the signup form with just email, and then I have a full page version of the signup form will all data.

What I'd like to do is a custom redirect after submitting the block form that puts them on the full page, pre-populated, and acts as an update form in case they'd like to add more data.

I know there is a hook for "mailchimp_subscribe_user", but that doesn't give me the data in the form context so I would have to grab it from the hook, save it to a session, (or something) and then use it in the next form.

Maybe there is another way to do this? If not, I have a small patch.

Speaking of 'mailchimp_subscribe_user', I noticed there was nothing in the mailchimp.api.php file as of yet, so I have another patch for that if it helps.

Thank you!

CommentFileSizeAuthor
results-in-form-state.patch870 bytesasherry
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jami’s picture

Status: Needs review » Needs work

Thank you for the patches, asherry!

I can definitely see the use case for this one. I wasn't able to get this patch to save anything to the form state on version 7.3.3, but this does seem like useful functionality.

ruscoe’s picture

Status: Needs work » Closed (won't fix)

We're going to be ending support for the 7.x-3.x branch due to the upcoming deprecation of the v2.0 MailChimp API. If you're still interested in this feature, please feel free to reopen for the 7.x-4.x branch.