So based on what's displayed on the "Mailchimp rewrite" information page, the MailChimp settings configuration for Drupal 7 should look like this: http://thinkshout.com/sites/default/files/mailchimp_6_settings.png

However, when I check the configuration page for MailChimp in v7.x-2.6, all I get under "Global Settings" is the API Key field, "Batch Limit", and the "Use Secure Connection" checkbox. Everything else in that image is nowhere to be found. Some of those settings look pretty useful, like "Anonymous Lists Messaging" and "Page Titles and Descriptions".

Right now I can't find any method to send anonymous users to a signup confirmation page, or to display a message to anonymous users in the browser, giving them further instructions (like "check your spam folder", etc).

Help on this would be great. Thanks!

Files: 

Comments

I think you're referring to a screenshot that applies to the MailChimp module BEFORE it was rewritten.

The first two screenshots seem to apply to the 'before' situation:
http://thinkshout.com/blog/2011/06/lev/mailchimp-20-anatomy-drupal-modul...

Maybe you're right, but it's a bit misleading. It says "Revamped User Interface" as the title of the section. The first image has no label, the next one says "Before" and the third one says "After".

Either way, I'm paying $10 a month for MailChimp's premium account right now, and it seems the Drupal module is incomplete. It's missing a lot of the functionality that's available on the actual MailChimp site, including adding a "Confirmation Page" or at the very least a "Confirmation Message" letting users know that they've successfully submitted the form.

Have a look in the /modules directory of the main module.

Enable the mailchimp_campaign and mailchimp_lists modules and you'll get more functionality.

Those modules are enabled. Where do I configure a confirmation page?

I would also WANT to redirect my subscriber to a thank you page or some sort of verification of subscription

I agree with Po3t, the mailchimp module seems very basic, specially if compared with the Constant Contact module. All of my clients use mailchimp, would be nice if this module got advanced.

Status:Active» Fixed

@Po3t, you can't configure a confirmation page, that's not a setting and not one we will add to the main module. It's simple enough to do, though, using a couple lines in hook_form_alter(). Most use cases do not call for a configurable confirmation page and we will not be adding features for fringe use cases to keep the settings reasonable.

@flock, the mailchimp module is under very active development with new commits within the last month as opposed to last April for Constant Contact. It also has over 5 times the number of users, so I'd say it's getting advanced plenty.

@levelos - How is a configurable confirmation page a "fringe use case"? A confirmation of subscription is a pretty common feature and the confirmation page is one of the basic pages to configure on the Mailchimp website. Right now when users sign up for the newsletter they have absolutely no way of knowing if it worked until they receive an email (especially considering most subscription confirmation emails end up in the junk mail folder). I'm not a custom drupal developer. I'm a front end designer and rely heavily on the Drupal Interface to configure my sites. How would I go about using "hook_form_alter()" for this? Normally I'd simply use a redirect rule, but Mailchimp options don't show up in the available actions.

Here here!

+1 for a confirmation page being *core business* for managing user experience properly, and the nice folks at MailChimp (who are sponsoring 7.2x development) would certainly appreciate this.

It seems very odd that the module's "completely refactored" architecture simply omits this side of the subscription workflow.

@levelos: clearly there's a bit of misunderstanding about the architectural strategy. Can you be a bit more clear on how the workflow is intended to function?

For instance, it seems wise that the module is not going to duplicate all the templating goodness already available on MailChimp...however the api clearly needs to hook into that workflow so that us admins can complete the required configurations.

Right now I have a support ticket open with MailChimp because their simple signup form link gets borked due to some javascript conflict coming from our default D7 install. The support people said "Hey, looks like Drupal is overwriting our javascript...why don't you try out our great Drupal integration" ...which is this module.

Okay, so now I can get a simple form presented on the site (that's the benefit of using this module right?) BUT it apparently comes at the cost of losing all the conditional logic and templating that is *core business* back on MailChimp?

Surely there's just a bit of misunderstanding here?

Status:Fixed» Active

StatusFileSize
new166.69 KB

Here was my solution. This code will extend the mailchimp module to add a field the the mailchimp admin settings form (see screenshot attachment). The field will allow you to identify a node that will serve as the confirmation page. When a user signs up they will directed to this node.

<?php
/**
* Implementation of hook_form_alter().
*/
function YOURMODULE_form_alter(&$form, &$form_state, $form_id) {
  switch (
$form_id) {
        case
'mailchimp_lists_user_subscribe_form_YOURLISTMACHINENAME':
           
$form['#submit'][] = 'YOURMODULE_confirmation_page';
        break;
        case
'mailchimp_admin_settings':
           
$form['mailchimp_confirmation'] = array(
               
'#type' => 'textfield',
               
'#title' => 'Confirmation Node ID',
            );
       
$form['#submit'][] = 'YOURMODULE_set_confirmation';
        break;
  }
}
function
YOURMODULE_confirmation_page($form, &$form_state) {
   
$thank_you_node = variable_get('mailchimp_confirmation_node', '');
   
drupal_goto('node/'.$thank_you_node);
}
function
YOURMODULE_set_confirmation($form, &$form_state){
    if(!empty(
$form_state['values']['mailchimp_confirmation'])){
       
variable_set('mailchimp_confirmation_node', $form_state['values']['mailchimp_confirmation']);
    }
}
?>

Should this be done on the actual list creation/edit page on the admin side instead of the general mailchimp settings? That way if you have multiple lists to manage different types of users you can have a separate confirmation page for your different lists.

Title:Missing MailChimp Configuration SettingsMissing MailChimp Configuration Settings - subscription confirmation
Component:General» Lists
Category:support» feature

Version:7.x-2.6» 7.x-2.9

Thanks for creating this but it doesn't seem to be working for me in that it doesn't redirect at all just reloads the current page. I'm assuming my machine name list is 1 because of mailchimp/lists/1/edit when I hover over the list on the configuration page.

The confirmation node appears on the Global configuration page but when I specify the node be it by number or alias and save the value disappears and I'm not sure what's going on, any ideas?

I had the same problem and I corrected it as :

<?php
/**
* Implementation of hook_form_alter().
*/
function YOURMODULE_form_alter(&$form, &$form_state, $form_id) {
  switch (
$form_id) {
        case
'mailchimp_lists_user_subscribe_form':
           
$form['#submit'][] = 'YOURMODULE_confirmation_page';
        break;
        case
'mailchimp_admin_settings':
           
$form['mailchimp_confirmation'] = array(
               
'#type' => 'textfield',
               
'#title' => 'Confirmation Node ID',
               
'#value' => variable_get('YOURMODULE_confirmation_node', ''),
            );
       
$form['#submit'][] = 'YOURMODULE_set_confirmation';
        break;
  }
}
function
YOURMODULE_confirmation_page($form, &$form_state) {
   
$thank_you_node = variable_get('mailchimp_confirmation_node', '');
   
drupal_goto('node/'.$thank_you_node);
}
function
YOURMODULE_set_confirmation($form, &$form_state){
    if(!empty(
$form_state['values']['mailchimp_confirmation'])){
       
variable_set('mailchimp_confirmation_node', $form_state['values']['mailchimp_confirmation']);
    }
}
?>

Also you must change "values" by "input" in YOURMODULE_set_confirmation like that :

<?php
function YOURMODULE_set_confirmation($form, &$form_state){
    if(!empty(
$form_state['input']['mailchimp_confirmation'])){
       
variable_set('mailchimp_confirmation_node', $form_state['input']['mailchimp_confirmation']);
    }
}
?>

Thanks but I've tried this and it just refreshes the current page. I also still have the issue of the confirmation node not being saved.

i think
'#value' => variable_get('YOURMODULE_confirmation_node', ''),
...should be...
'#value' => variable_get('mailchimp_confirmation_node', ''),

hello,
in order to keep the value of the textfield i changed the line
'#value' => variable_get('YOURMODULE_confirmation_node', ''),
to
'#default_value' => variable_get('YOURMODULE_confirmation_node', ''),

also, in line
case 'mailchimp_lists_user_subscribe_form':
i changed the form ID because in my form was different from that.
The redirect to thank you page works well.

this is pretty hacky but worked for me to add a redirect to each list instead of global. You may have to save list settings once before field shows up. Also, yes, the field is below the save button. I don't have time to figure out why that is for now. Modified from the above code. D7:

/**
* Implementation of hook_form_alter().
*/
function MODULENAME_form_alter(&$form, &$form_state, $form_id) {
  switch ($form_id) {
        case 'mailchimp_lists_list_form':
            if($form['name']['#default_value'] !=''):
    $this_form_name = $form['name']['#default_value'];
    $this_confirmation_var = 'mc_confirmation_node_'.$this_form_name;
    $form['mailchimp_confirmation'] = array(
                '#type' => 'textfield',
            '#title' => 'Confirmation Node ID',
            '#value' => variable_get($this_confirmation_var, ''),
           );
            $form['#submit'][] = 'MODULENAME_set_confirmation';
    endif;
        break;
  }
    if(substr($form_id,0,35)=='mailchimp_lists_user_subscribe_form'):
$form['#submit'][] = 'MODULENAME_confirmation_page';
    endif;
}
function MODULENAME_confirmation_page($form, &$form_state, $form_id) {
    $this_confirmation_var = 'mc_confirmation_node_'.substr($form['#form_id'],36);
    $thank_you_node = variable_get($this_confirmation_var, '');
    drupal_goto('node/'.$thank_you_node);
}
function MODULENAME_set_confirmation($form, &$form_state){
    if(!empty($form_state['values']['mailchimp_confirmation'])){
        $this_confirmation_var = 'mc_confirmation_node_'.$form['name']['#default_value'];
variable_set($this_confirmation_var, $form_state['values']['mailchimp_confirmation']);
    }
    if(!empty($form_state['input']['mailchimp_confirmation'])){
        $this_confirmation_var = 'mc_confirmation_node_'.$form['name']['#default_value'];
variable_set($this_confirmation_var, $form_state['input']['mailchimp_confirmation']);
    }
}

Note that if you're using the signup form in a block and the user is anonymous that the form_id will not be written the same way as the code above. For example, you might have "mailchimp_subscribe_anon_form_IDstring" (the word IDstring being the unique code that is loaded into the display code. You'll need to copy your form_id into the code supplied by C2is and make the aforementioned adjustments recommended by achilleas01 and you should be in business. I used this to successfully redirect and anonymous user from the page with the mailchimp form (in a block) to the confirmation page. I hope this helps someone who was scratching their head on this. Also note that the position in which you insert C2is's code in the mailchimp.module may affect where in the Global Configuration form it may appear. I was unclear as to what line it should start/end. Therefore, my field as defined by the snippet above appeared after the submit button, but I don't believe that mattered to the form's proper function (this time). More specifics on where to insert code would be helpful for the novices I think...well, I know, being a novice, it would have helped me. Thank you so much for the effort to decipher this issue everyone!

Is really a must have feature for the users, because there's no way of them to know that they have successfully subscribed to the newsletter.

Version:7.x-2.9» 7.x-2.12

Impressive that after a year and a day there's no answer to that question on such an "active" development module. It is sad to see that the developer considers that having feedback after registering is not important at all and doesn't require any effort on his part, that it is basically a non-sense that every user should solve... if he's having PHP skills... on the other hand it would be so easy to provide a Rules action just reacting to a subscription (anonymous or not)...

Apart from that Problem there are others, but for me right now it is essential that I can tell people:

Hey, you have just subscribed to our newsletter, watch out for
newsletter@Example.com... you may want to add this address to your contactlist and you have to activate the subscription by clicking a link in the first email just send...blablabla

And YES, me too don't thinks this is a side issue. Still. Almost 2014.

Issue summary:View changes

I assume nothing has been done here. Has anybody found a solution to this problem? It is 2014 now, and I would love to know how to address this problem!