Is there an elegant way (without hacking the plugin's code) to integrate a Contact Form 7 contact form to Mailchimp, so I can have a checkbox that when selected would register the email to a Mailchimp list?
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It only takes a minute to sign up.Sign up to join this community
You can use my plugin called MailChimp for WordPress to do this.
When installed, you can select one or multiple lists in the plugin settings and use the following shortcode inside your Contact Form 7 templates.
[mc4wp_checkbox "Your label text"]
It will render a checkbox and when checked, subscribe the given email address to the MailChimp lists you selected.
PS. I realize this question is over 2 years old. Just answering in case anyone else stumbles across it. Some answers had been given but I am pretty sure this is by far the easiest way to do it.
This is what finally worked for me. The code needs to be updated tho. I don't have time now to get back to the refactored code but if someone requests it I will do it in due time.
This might work for you...
You'll still possibly have to modify the contact form's files but only to do this:
"You can manually place the checkbox by calling inside the form tags of your comment form."