Page 22 of 41 FirstFirst ... 12202122232432 ... LastLast
Results 211 to 220 of 402
  1. #211
    Join Date
    Jun 2005
    Posts
    18
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    Quote Originally Posted by swguy View Post
    Did you verify that they checked the newsetter box? Did you try printing the value of $newsletter before the if statement?
    Yep, I tested the process myself - tested with both checked and unchecked.

    I added the value of the $newsletter in my ZC intro email to discover it was always 0.

    I'm not a php programmer but following the logic of the includes/code it appears that another plugin (how_did_you_hear_about_us_v150) had modified this bit of code in the file "tpl_modules_create_account.php"

    <?php echo '<label class="m-checkbox m-wrap" for="newsletter-checkbox">' . zen_draw_checkbox_field('newsletter', '0', $newsletter, 'id="newsletter-checkbox"') . ENTRY_NEWSLETTER . '</label>' . (zen_not_null(ENTRY_NEWSLETTER_TEXT) ? '<span class="alert">' . ENTRY_NEWSLETTER_TEXT . '</span>': ''); ?>
    <br class="clearBoth" /

    I diff'd this with the same file pre-installation version of the same file and saw that 'newsletter', '0' was 'newsletter', '1'

    Setting this back to 1 seems to have activated the newsletter subscribes. Not sure what the ramifications of the change I've made will have...

    ...but I guess that's an issue for the other plugin not this one.

    Thanks for your pointer.

    Troy.

  2. #212
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: MailChimp Newsletter Sidebox

    Quote Originally Posted by mikecnz View Post
    Hi,

    I got this to work with FEC,

    simply add the code

    if ((int)$newsletter == 1) {
    mailchimp_add($email_address, $firstname, $lastname, $email_format);
    }

    to /includes/modules/fec_create_account instead of /includes/modules/your-template/create_account and follow the instructions above for includes/functions/extra_functions/mailchimp_functions.php. I made a typo in mailchimp_functions.php hence the reason for my e-mail above - but once I fixed it, everything worked as it should.
    I did this (with the exception of adding the additional fields) and I cannot get the mailchimp to kick in when the newsletter box is clicked when using Fast Easy Checkout. Scott - do you have any recommendations? Or should I ask Jeff at Numinix?

    Thanks for any help you can give me!

  3. #213
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: MailChimp Newsletter Sidebox

    Just as an FYI - I WAS getting the double optin emails - they were going to JUNK folder, so I did not see them! Everything worked perfectly! LOL

    Now I am on a mission to figure out how to get the newsletter signup "box" to be in a header or footer of a site. Any suggestions will be welcomed!

    Quote Originally Posted by stellarweb View Post
    I did this (with the exception of adding the additional fields) and I cannot get the mailchimp to kick in when the newsletter box is clicked when using Fast Easy Checkout. Scott - do you have any recommendations? Or should I ask Jeff at Numinix?

    Thanks for any help you can give me!

  4. #214
    Join Date
    Aug 2012
    Posts
    331
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    Hello,
    I'm using the add customer mod to add customer from admin, can we trigger mailchimp when adding a customer from admin? i assume this
    PHP Code:
       if ((int)$newsletter == 1) { 
           
    mailchimp_add($email_address$email_format);
       } 
    is suppose to go in somewhere in the add_customers.php file

    Here is the contents of my add_customers.php:
    PHP Code:
    <?php
    /**
     * @copyright Copyright 2003-2010 Zen Cart Development Team
     * @copyright Portions Copyright 2003 osCommerce
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     *
     * add_customers module modified by Garden 2012-07-20
     * www.inzencart.cz Czech forum for ZenCart
     * Modified for Zen Cart 1.5.0, lat9 2012-08-31
     */
    require('includes/application_top.php');

    require(
    DIR_WS_CLASSES 'currencies.php');
    $currencies = new currencies();

    $action = (isset($_POST['action'])) ? $_POST['action'] : false;
    $error false;
    $processed false;
    $cInfo = array();
    $theFormats = array('YYYY/MM/DD''MM/DD/YYYY''YYYY-MM-DD''MM-DD-YYYY''YYYY/DD/MM''DD/MM/YYYY''YYYY-DD-MM''DD-MM-YYYY');

    require_once(
    'add_customers_backend.php');

    // ---- Determine what to do next ... single add vs. country change vs. multiple/file add
    if (zen_not_null($action)) {
      switch (
    $action) {
        case 
    'add_single':
          
    $array validate_customer($_POST'date_format_s');
          
    $errors $array['errors'];
          
    $cInfo $array['cInfo'];

          if (
    count($errors) < 1) {
            
    $customerName insert_customer($_POST);
            
    $feedback sprintfMESSAGE_CUSTOMER_OK$customerName);
          }
          break;
          
        case 
    'add_multiple':
          
    $array check_file_upload();
          
    $errors $array['errors'];
          
    $feedback $array['feedback'];
          break;
          
        case 
    'resend_email':
          if (!isset(
    $_POST['resend_id'])) {
            
    $errors[] = ERROR_NO_CUSTOMER_SELECTED;
            
          } else {      
            
    $sql "SELECT customers_gender, customers_firstname, customers_lastname, customers_email_address FROM " TABLE_CUSTOMERS " WHERE customers_id = '" . (int)$_POST['resend_id'] . "'";
            
    $custInfo $db->Execute($sql);
            if (
    $custInfo->RecordCount() == 0) {
              
    $errors[] = ERROR_NO_CUSTOMER_SELECTED;
              
            } else {
              
    $thePassword false;
              if (isset(
    $_POST['reset_pw']) && $_POST['reset_pw'] == 1) {
                
    $thePassword zen_create_random_value(ENTRY_PASSWORD_MIN_LENGTH);
                
    $sql "UPDATE " TABLE_CUSTOMERS "
                        SET customers_password = '" 
    zen_encrypt_password($thePassword) . "'
                        where customers_id = '" 
    . (int)$_POST['resend_id'] . "'";
                
    $db->Execute($sql);
              }
              
    sendWelcomeEmail ($custInfo->fields['customers_gender'], $custInfo->fields['customers_firstname'], $custInfo->fields['customers_lastname'], $custInfo->fields['customers_email_address'], $thePassword);
              
              
    $feedback[] = CUSTOMER_EMAIL_RESENT;
            }
          }
          break;
          
        default:
          break;
      }
    }
    ?>
    <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html <?php echo HTML_PARAMS?>>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET?>">
    <title><?php echo TITLE?></title>
    <link rel="stylesheet" type="text/css" href="includes/stylesheet.css">
    <link rel="stylesheet" type="text/css" href="includes/stylesheet_acfa.css">
    <link rel="stylesheet" type="text/css" href="includes/cssjsmenuhover.css" media="all" id="hoverJS">

    <script type="text/javascript" src="includes/menu.js"></script>
    <script type="text/javascript" src="includes/general.js"></script>
    <script type="text/javascript">

    function init()
    {
      cssjsmenu(\'navbar\');
      if (document.getElementById)
      {
        var kill = document.getElementById(\'hoverJS\');
        kill.disabled = true;
      }
    }

    </script>

    </head>

    <body onLoad="init()">
    <?php
    require(DIR_WS_INCLUDES 'header.php');

    $infoDivContents '';
    if (
    count($errors) > 0) {
      
    $infoDivContents '<div class="errorDiv"><p class="errorBold">' ERROR_CUSTOMER_ERROR_1 . (($action == 'insert_multiple' && zen_not_null($_FILES['bulk_upload']['name'])) ? (' (' $_FILES['bulk_upload']['name'] . ')') : '') . ':' '</p><ul>';

      foreach (
    $errors as $line_no=>$error) {
        if (
    is_array($error)) {
          
    $infoDivContents .= '<div class="error">' sprintf(ERROR_ON_LINE, ($line_no+1)) . '</div><ul>';

          foreach (
    $error as $err) {
            
    $infoDivContents .= '<li class="error">' $err'</li>';
          }
          
    $infoDivContents .= '</ul>';
        } else {
          
    $infoDivContents .= '<li class="error">' $error '</li>';
        }
      }
      
      
    $infoDivContents .= '</ul></div>';
    }

    if (
    count($feedback)) {
      
    $infoDivContents .= '<div class="okDiv"><p class="okBold">' . ((count($errors) && $_POST['insert_mode'] == 'file') ? MESSAGE_LINES_OK_NOT_INSERTED MESSAGE_CUSTOMERS_OK) . '</p><ul>';
     
      foreach (
    $feedback as $line_no=>$feedback_msg) {
        
    $infoDivContents .= '<li class="ok">' . (($feedback_msg != '' && !is_array($feedback_msg)) ? $feedback_msg sprintf(LINE_MSG$line_no+1$feedback_msg['customers_firstname'], $feedback_msg['customers_lastname'])) . '</li>';
      }
      
      
    $infoDivContents .= '</ul></div>';
    }

    $insert_mode = (isset($_POST['insert_mode'])) ? $_POST['insert_mode'] : 'file';
    $newsletter_array = array( array('id' => '1''text' => ENTRY_NEWSLETTER_YES), array('id' => '0''text' => ENTRY_NEWSLETTER_NO) );

    if (isset(
    $_POST['date_format_m'])) {
      
    $selectedDateFormat_m = (int)$_POST['date_format_m'];
    } else {
      
    $currentDateFormat_m str_replace('%m''MM'str_replace('%d''DD'str_replace('%Y''YYYY'DATE_FORMAT_SHORT)));
      
    $selectedDateFormat_m array_search($currentDateFormat_m$theFormats);
    }
    if (isset(
    $_POST['date_format_s'])) {
      
    $selectedDateFormat_s = (int)$_POST['date_format_s'];
    } else {
      
    $currentDateFormat_s str_replace('%m''MM'str_replace('%d''DD'str_replace('%Y''YYYY'DATE_FORMAT_SHORT)));
      
    $selectedDateFormat_s array_search($currentDateFormat_s$theFormats);
    }

    for (
    $i=0$n=sizeof($theFormats), $dateFormats=array(); $i<$n$i++) {
      
    $dateFormats[$i]['id'] = $i;
      
    $dateFormats[$i]['text'] = $theFormats[$i];
    }

    $resendID = (isset($_POST['resend_id'])) ? $_POST['resend_id'] : 0;
    ?>
      <h1><?php echo HEADING_TITLE?></h1>
      <table border="0" width="100%" cellspacing="2" cellpadding="2">
        <tr>
          <td width="100%" valign="top">
            <table border="0" width="100%" cellspacing="0" cellpadding="2">
              <tr>
                <td id="multiple"><table border="0" cellspacing="2" cellpadding="2">
                  <tr>
                    <td id="csv_in">
                      <div class="headingLabel"><?php echo CUSTOMERS_BULK_UPLOAD?></div>
                  <?php if ($action == 'add_multiple') echo $infoDivContents?>
                  <?php echo zen_draw_form('customers'FILENAME_ADD_CUSTOMERS'''post''enctype="multipart/form-data"') . zen_hide_session_id(). zen_draw_hidden_field'action''add_multiple'); ?>
                        <div class="formArea"><table border="0" cellspacing="2" cellpadding="2">
                          <tr>
                            <td><div class="back mainLabel"><?php echo CUSTOMERS_FILE_IMPORT?></div><input type="file" name="bulk_upload" /></td>
                          </tr>
                          <tr>
                            <td>
                              <div class="back mainLabel"><?php echo CUSTOMERS_INSERT_MODE?></div>
                              <div class="back">
                                <input type="radio" name="insert_mode" value="part" <?php echo ($insert_mode == 'part') ? 'checked="checked"' ''?>/><?php echo CUSTOMERS_INSERT_MODE_VALID?><br />
                                <input type="radio" name="insert_mode" value="file" <?php echo ($insert_mode == 'file') ? 'checked="checked"' ''?>/><?php echo CUSTOMERS_INSERT_MODE_FILE?>
                              </div>
                            </td>
                          </tr>
                          <tr>
                            <td><div class="back mainLabel"><?php echo DATE_FORMAT_CHOOSE_MULTI?></div><?php echo zen_draw_pull_down_menu('date_format_m'$dateFormats$selectedDateFormat_m); ?></td>
                          </tr>
                          <tr>
                            <td>
                              <div style="width:350px; text-align: right;">
                                <a href="<?php echo HTTP_SERVER DIR_WS_CATALOG?>add_customers_formatting_csv.html" target="_blank"><?php echo FORMATTING_THE_CSV?></a>&nbsp;<input type="submit" name="add_customers_in_bulk" value="Upload" />
                              </div>
                            </td>
                          </tr>
                        </table></div>
                      </form>
                    </td>
                  </tr>
                  
                  <tr>
                    <td>
                      <div class="headingLabel"><?php echo RESEND_WELCOME_EMAIL?></div>
                  <?php if ($action == 'resend_email') echo $infoDivContents?>
                  <?php echo zen_draw_form('resend'FILENAME_ADD_CUSTOMERS'''post''enctype="multipart/form-data"') . zen_hide_session_id() . zen_draw_hidden_field ('action''resend_email'); ?>
                        <div class="formArea"><table border="0" cellspacing="2" cellpadding="2">
                          <tr>
                            <td><div class="back mainLabel"><?php echo TEXT_CHOOSE_CUSTOMER?></div><div class="main"><?php echo zen_draw_pull_down_menu('resend_id'create_customer_drop_down(), $resendID); ?></div></td>
                          </tr>
                          <tr class="clearBoth">
                            <td><div class="back mainLabel"><?php echo TEXT_RESET_PASSWORD?></div><div class="main"><input type="checkbox" id="reset_pw" value="1" name="reset_pw" <?php echo (isset($_POST['reset_pw'])) ? 'checked="checked"' ''?>/></div></td>
                          </tr>
                          <tr>
                            <td>
                              <div style="width:350px; text-align: right;">
                                <input type="submit" name="resend" value="<?php echo BUTTON_RESEND?>" />
                              </div>
                            </td>
                          </tr>
                        </table></div>
                      </form>
                    </td>
                  </tr>
                </table></td>
                
                <td id="single"><div class="headingLabel"><?php echo CUSTOMERS_SINGLE_ENTRY?></div><?php if ($action == 'add_single' && zen_not_null($_POST['insert_x']) && zen_not_null($_POST['insert_y'])) echo $infoDivContents?><?php echo zen_draw_form('customers_1'FILENAME_ADD_CUSTOMERS'''post') . zen_hide_session_id() . zen_draw_hidden_field'action''add_single'); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">
                  <tr>
                    <td class="formAreaTitle"><?php echo CATEGORY_PERSONAL?></td>
                  </tr>
                  <tr>
                    <td class="formArea"><table border="0" cellspacing="2" cellpadding="2">
    <?php
      $customers_authorization_array 
    = array( array('id' => '0''text' => CUSTOMERS_AUTHORIZATION_0),
                                              array(
    'id' => '1''text' => CUSTOMERS_AUTHORIZATION_1),
                                              array(
    'id' => '2''text' => CUSTOMERS_AUTHORIZATION_2),
                                              array(
    'id' => '3''text' => CUSTOMERS_AUTHORIZATION_3)
                                            );
    ?>
                      <tr>
                        <td class="main mainLabel"><?php echo CUSTOMERS_AUTHORIZATION?></td>
                        <td class="main"><?php echo zen_draw_pull_down_menu('customers_authorization'$customers_authorization_array$cInfo->customers_authorization); ?></td>
                      </tr>              
    <?php
      
    if (ACCOUNT_GENDER == 'true') {
    ?>
                      <tr>
                        <td class="main mainLabel" style="vertical-align:top;"><?php echo ENTRY_GENDER?></td>
                        <td class="main">
                          <input type="radio" name="customers_gender" value="m" <?php echo ($cInfo->customers_gender == 'm') ? 'checked' ''?> /><?php echo MALE?>
                          <span class="spacer"></span>
                          <input type="radio" name="customers_gender" value="f" <?php echo ($cInfo->customers_gender == 'f') ? 'checked' ''?> /><?php echo FEMALE?>
                        </td>
                      </tr>
    <?php
      
    }
    ?>
                      <tr>
                        <td class="main mainLabel"><?php echo ENTRY_FIRST_NAME?></td>
                        <td class="main"><input size="30" name="customers_firstname" value="<?php echo $cInfo->customers_firstname?>" /></td>
                      </tr>

                      <tr>
                        <td class="main mainLabel"><?php echo ENTRY_LAST_NAME?></td>
                        <td class="main"><input size="30" name="customers_lastname" value="<?php echo $cInfo->customers_lastname?>" /></td>
                      </tr>
    <?php
      
    if (ACCOUNT_DOB == 'true') {
    ?>
                    <tr>
                      <td class="back mainLabel"><?php echo DATE_FORMAT_CHOOSE_SINGLE?></td>
                      <td class="main"><?php echo zen_draw_pull_down_menu('date_format_s'$dateFormats$selectedDateFormat_s); ?></td>
                      </tr>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_DATE_OF_BIRTH?></td>
                      <td class="main"><input size="30" name="customers_dob" value="<?php echo $cInfo->customers_dob?>" /></td>
                    </tr>
    <?php
      
    }
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_EMAIL_ADDRESS?></td>
                      <td class="main"><input size="30" name="customers_email_address" value="<?php echo $cInfo->customers_email_address?>" /></td>
                    </tr> 

                  </table></td>
                </tr>
    <?php
      
    if (ACCOUNT_COMPANY == 'true') {
    ?>
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formAreaTitle"><?php echo CATEGORY_COMPANY?></td></tr>
                <tr>
                  <td class="formArea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_COMPANY?></td>
                      <td class="main"><input size="30" name="entry_company" value="<?php echo $cInfo->entry_company?>" /></td>
                    </tr>
                  </table></td>
                </tr>
    <?php
      
    }
    ?>
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formAreaTitle"><?php echo CATEGORY_ADDRESS?></td></tr>
                <tr>
                  <td class="formArea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main Label"><?php echo ENTRY_STREET_ADDRESS?></td>
                      <td class="main"><input size="30" name="entry_street_address" value="<?php echo $cInfo->entry_street_address?>" /></td>
                    </tr>           
    <?php
      
    if (ACCOUNT_SUBURB == 'true') {
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_SUBURB?></td>
                      <td class="main"><input size="30" name="entry_suburb" value="<?php echo $cInfo->entry_suburb?>" /></td>
                    </tr>
    <?php              
      
    }
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_CITY?></td>
                      <td class="main"><input size="30" name="entry_city" value="<?php echo $cInfo->entry_city?>" /></td>
                    </tr>                                   

                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_POST_CODE?></td>
                      <td class="main"><input size="30" name="entry_postcode" value="<?php echo $cInfo->entry_postcode?>" /></td>
                    </tr>
                  
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_COUNTRY?></td>
                      <td class="main"><?php echo zen_draw_pull_down_menu('entry_country_id'zen_get_countries(), (zen_not_null($cInfo->entry_country_id) ? $cInfo->entry_country_id SHOW_CREATE_ACCOUNT_DEFAULT_COUNTRY), 'onchange="this.form.submit();"'); ?></td>
                    </tr>
    <?php
      
    if (ACCOUNT_STATE == 'true') {
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_STATE?></td>
                      <td class="main">
    <?php
        $theZones 
    zen_prepare_country_zones_pull_down ((zen_not_null($cInfo->entry_country_id) ? $cInfo->entry_country_id SHOW_CREATE_ACCOUNT_DEFAULT_COUNTRY));
        if (
    count($theZones) > 1) {
          echo 
    zen_draw_pull_down_menu('entry_zone_id'$theZones$cInfo->entry_zone_id);
          
        } else {
          
    $entry_state zen_get_zone_name($cInfo->entry_country_id$cInfo->entry_zone_id$cInfo->entry_state);
          echo 
    zen_draw_input_field('entry_state'zen_get_zone_name($cInfo->entry_country_id$cInfo->entry_zone_id$cInfo->entry_state));
        }
      }
    ?>
                      </td>
                    </tr>
                  </table></td>
                </tr>
              
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formAreaTitle"><?php echo CATEGORY_CONTACT?></td></tr>
                <tr>
                  <td class="formArea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_TELEPHONE_NUMBER?></td>
                      <td class="main"><input size="30" name="customers_telephone" value="<?php echo $cInfo->customers_telephone?>" /></td>
                    </tr>
    <?php
      
    if (ACCOUNT_FAX_NUMBER == 'true') {
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_FAX_NUMBER?></td>
                      <td class="main"><input size="30" name="customers_fax" value="<?php echo $cInfo->customers_fax?>" /></td>
                    </tr>
    <?php
      
    }
    ?>
                  </table></td>
                </tr>
              
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formAreaTitle"><?php echo CATEGORY_OPTIONS?></td></tr>
                <tr>
                  <td class="formArea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_EMAIL_PREFERENCE?></td>
                      <td class="main">
    <?php
      $email_pref_text 
    = ( (empty($cInfo) && ACCOUNT_EMAIL_PREFERENCE != '1') || $cInfo->customers_email_format == 'TEXT' ) ? true false;
      
    $email_pref_html = !$email_pref_text;
      echo 
    zen_draw_radio_field('customers_email_format''HTML'$email_pref_html) . '&nbsp;' ENTRY_EMAIL_HTML_DISPLAY '&nbsp;&nbsp;&nbsp;' zen_draw_radio_field('customers_email_format''TEXT'$email_pref_text) . '&nbsp;' ENTRY_EMAIL_TEXT_DISPLAY ;
    ?>
                      </td>
                    </tr>
                  
                    <tr>
                      <td class="main Label"><?php echo ENTRY_NEWSLETTER?></td>
                      <td class="main"><?php echo zen_draw_pull_down_menu('customers_newsletter'$newsletter_array, (($cInfo->customers_newsletter == '1') ? '1' '0')); ?></td>
                    </tr>
                  
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_PRICING_GROUP?></td>
                      <td class="main">
    <?php
      $group_array_query 
    $db->execute("select group_id, group_name, group_percentage from " TABLE_GROUP_PRICING);
      
    $group_array[] = array('id'=>0'text'=>TEXT_NONE);

      while (!
    $group_array_query->EOF) {
        
    $group_array[] = array('id'=>$group_array_query->fields['group_id'], 'text'=>$group_array_query->fields['group_name'].'&nbsp;'.$group_array_query->fields['group_percentage'].'%');
        
    $group_array_query->MoveNext();
      }

      echo 
    zen_draw_pull_down_menu('customers_group_pricing'$group_array$cInfo->customers_group_pricing);
    ?>
                      </td>
                    </tr>
    <?php
      
    if (CUSTOMERS_REFERRAL_STATUS == 2) {
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo CUSTOMERS_REFERRAL?></td>
                      <td class="main"><?php echo zen_draw_input_field('customers_referral'$cInfo->customers_referralzen_set_field_length(TABLE_CUSTOMERS'customers_referral'15)); ?></td>
                    </tr>
    <?php
      
    }
    ?>
                    <tr>
                      <td class="main mainLabel"><?php echo ENTRY_EMAIL?></td>
                      <td class="main"><input type="checkbox" id="send_welcome" value="1" name="send_welcome" <?php echo (isset($_POST['send_welcome'])) ? 'checked="checked"' ''?>/></td>
                    </tr>
                  </table></td>
                </tr>
              
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr>
                  <td align="right" class="main"><?php echo zen_image_submit('button_insert.gif'IMAGE_UPDATE'name="insert"'); ?><a href="<?php echo zen_href_link(FILENAME_CUSTOMERSzen_get_all_get_params(array('action')), 'NONSSL'); ?>"><?php echo zen_image_button('button_cancel.gif'IMAGE_CANCEL); ?></a></td>
                </tr>
              </table></form></td></tr>

          </table>
        </td>
      </tr>
    </table>
    <?php
    require(DIR_WS_INCLUDES 'footer.php');
    ?>
    <br />
    </body>
    </html>
    <?php
    require(DIR_WS_INCLUDES 'application_bottom.php');
    ?>

  5. #215
    Join Date
    May 2011
    Location
    Nova Scotia
    Posts
    35
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    Quote Originally Posted by MaartenJ View Post
    Allright, coded the update function after my diner. When a customer updates his or her information on the "my account" page, this change will be synced with your Mail Chimp list. Here's how I dit it:

    In mailchimp_functions.php from this great module I added my own function at the end of the file. Note that I added a field for Firstname and Lastname. You can do that, but if you don't want to just delete everything with firstname and lastname in it:

    PHP Code:
    //Mailchimp update function: update customers data to the mailchimp list.
     
    function mailchimp_update($email_address_old$email_address$firstname$lastname$email_format) {
        include_once(
    DIR_WS_CLASSES "MCAPI.class.php");
        
    $api = new MCAPI(BOX_MAILCHIMP_NEWSLETTER_API_KEY);
        
    $merge_vars = array('FNAME'=>$firstname'LNAME'=>$lastname'EMAIL'=>$email_address);
        if (
    $email_format == 'TEXT') {
           
    $format 'text'
        } else {
           
    $format 'html'
        }

        
    $list_id BOX_MAILCHIMP_NEWSLETTER_ID
        
    $retval $api->listUpdateMember($list_id$email_address_old$merge_vars$format);
        if (
    $api->errorCode){
            
    $errorMessage "Unable to update member info with listUpdateMember()!\n" 
               
    "\tCode=".$api->errorCode."\n" .
               
    "\tMsg=".$api->errorMessage."\n";
              
    $file DIR_FS_SQL_CACHE '/' 'MailChimp.log';
              if (
    $fp = @fopen($file'a')) {
                
    fwrite($fp$errorMessage);
                
    fclose($fp);
              }
        }
     } 
    In htdocs/includes/templates/YOURTEMPLATE/templates/tpl_account_edit_default.php you must make an invisible field to be able to pass the old email address (email_address_old) to the mailchimp_update() function. I've placed this line below the entry for the e-mail address, but you can paste in anywhere as long as it is within the form:

    PHP Code:
    <?php echo zen_draw_hidden_field('email_address_old'$account->fields['customers_email_address'], 'id="email-address-old"'?>
    At last you must make a call to the function. When the form is submitted it will use /includes/modules/pages/account_edit/header_php.php to make all the magic happen. Paste the following around line 154 above the line:
    $zco_notifier->notify('NOTIFY_HEADER_ACCOUNT_EDIT_UPDATES_COMPLETE');

    PHP Code:
    mailchimp_update($email_address_old$email_address$firstname$lastname$email_format); 
    That's all! Now your mailchimp list will be updated as soon as your customer edits his or her information! Next thing to do is to make a sync for the "Subscribe or unsubscribe from newsletters." page.
    I would like to do this can anyone see if there is anything wrong with the code above as my customers can sign up using create account or side box it works perfect. If that person unsubscribes from my account link it works fine but if they click the check-box from my account to signup again it does not resign them up.

  6. #216
    Join Date
    Aug 2012
    Posts
    331
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    Quote Originally Posted by shopville View Post
    hello,
    i'm using the add customer mod to add customer from admin, can we trigger mailchimp when adding a customer from admin? I assume this
    PHP Code:
       if ((int)$newsletter == 1) { 
           
    mailchimp_add($email_address$email_format);
       } 
    is suppose to go in somewhere in the add_customers.php file

    here is the contents of my add_customers.php:
    PHP Code:
    <?php
    /**
     * @copyright copyright 2003-2010 zen cart development team
     * @copyright portions copyright 2003 oscommerce
     * @license http://www.zen-cart.com/license/2_0.txt gnu public license v2.0
     *
     * add_customers module modified by garden 2012-07-20
     * www.inzencart.cz czech forum for zencart
     * modified for zen cart 1.5.0, lat9 2012-08-31
     */
    require('includes/application_top.php');

    require(
    dir_ws_classes 'currencies.php');
    $currencies = new currencies();

    $action = (isset($_post['action'])) ? $_post['action'] : False;
    $error false;
    $processed false;
    $cinfo = array();
    $theformats = array('yyyy/mm/dd''mm/dd/yyyy''yyyy-mm-dd''mm-dd-yyyy''yyyy/dd/mm''dd/mm/yyyy''yyyy-dd-mm''dd-mm-yyyy');

    require_once(
    'add_customers_backend.php');

    // ---- determine what to do next ... Single add vs. Country change vs. Multiple/file add
    if (zen_not_null($action)) {
      switch (
    $action) {
        case 
    'add_single':
          
    $array validate_customer($_post'date_format_s');
          
    $errors $array['errors'];
          
    $cinfo $array['cinfo'];

          if (
    count($errors) < 1) {
            
    $customername insert_customer($_post);
            
    $feedback sprintfmessage_customer_ok$customername);
          }
          break;
          
        case 
    'add_multiple':
          
    $array check_file_upload();
          
    $errors $array['errors'];
          
    $feedback $array['feedback'];
          break;
          
        case 
    'resend_email':
          If (!isset(
    $_post['resend_id'])) {
            
    $errors[] = error_no_customer_selected;
            
          } else {      
            
    $sql "select customers_gender, customers_firstname, customers_lastname, customers_email_address from " Table_customers " where customers_id = '" . (int)$_post['resend_id'] . "'";
            
    $custinfo $db->execute($sql);
            if (
    $custinfo->recordcount() == 0) {
              
    $errors[] = error_no_customer_selected;
              
            } else {
              
    $thepassword false;
              if (isset(
    $_post['reset_pw']) && $_post['reset_pw'] == 1) {
                
    $thepassword zen_create_random_value(entry_password_min_length);
                
    $sql "update " Table_customers "
                        set customers_password = '" 
    Zen_encrypt_password($thepassword) . "'
                        where customers_id = '" 
    . (int)$_post['resend_id'] . "'";
                
    $db->execute($sql);
              }
              
    sendwelcomeemail ($custinfo->fields['customers_gender'], $custinfo->fields['customers_firstname'], $custinfo->fields['customers_lastname'], $custinfo->fields['customers_email_address'], $thepassword);
              
              
    $feedback[] = customer_email_resent;
            }
          }
          break;
          
        default:
          Break;
      }
    }
    ?>
    <!doctype html public "-//w3c//dtd html 4.01 transitional//en">
    <html <?php echo html_params?>>
    <head>
    <meta http-equiv="content-type" content="text/html; charset=<?php echo charset?>">
    <title><?php echo title?></title>
    <link rel="stylesheet" type="text/css" href="includes/stylesheet.css">
    <link rel="stylesheet" type="text/css" href="includes/stylesheet_acfa.css">
    <link rel="stylesheet" type="text/css" href="includes/cssjsmenuhover.css" media="all" id="hoverjs">

    <script type="text/javascript" src="includes/menu.js"></script>
    <script type="text/javascript" src="includes/general.js"></script>
    <script type="text/javascript">

    function init()
    {
      cssjsmenu(\'navbar\');
      if (document.getelementbyid)
      {
        var kill = document.getelementbyid(\'hoverjs\');
        kill.disabled = true;
      }
    }

    </script>

    </head>

    <body onload="init()">
    <?php
    require(dir_ws_includes 'header.php');

    $infodivcontents '';
    if (
    count($errors) > 0) {
      
    $infodivcontents '<div class="errordiv"><p class="errorbold">' Error_customer_error_1 . (($action == 'insert_multiple' && zen_not_null($_files['bulk_upload']['name'])) ? (' (' $_files['bulk_upload']['name'] . ')') : '') . ':' '</p><ul>';

      foreach (
    $errors as $line_no=>$error) {
        if (
    is_array($error)) {
          
    $infodivcontents .= '<div class="error">' Sprintf(error_on_line, ($line_no+1)) . '</div><ul>';

          foreach (
    $error as $err) {
            
    $infodivcontents .= '<li class="error">' $err'</li>';
          }
          
    $infodivcontents .= '</ul>';
        } else {
          
    $infodivcontents .= '<li class="error">' $error '</li>';
        }
      }
      
      
    $infodivcontents .= '</ul></div>';
    }

    if (
    count($feedback)) {
      
    $infodivcontents .= '<div class="okdiv"><p class="okbold">' . ((count($errors) && $_post['insert_mode'] == 'file') ? Message_lines_ok_not_inserted Message_customers_ok) . '</p><ul>';
     
      foreach (
    $feedback as $line_no=>$feedback_msg) {
        
    $infodivcontents .= '<li class="ok">' . (($feedback_msg != '' && !is_array($feedback_msg)) ? $feedback_msg Sprintf(line_msg$line_no+1$feedback_msg['customers_firstname'], $feedback_msg['customers_lastname'])) . '</li>';
      }
      
      
    $infodivcontents .= '</ul></div>';
    }

    $insert_mode = (isset($_post['insert_mode'])) ? $_post['insert_mode'] : 'file';
    $newsletter_array = array( array('id' => '1''text' => entry_newsletter_yes), array('id' => '0''text' => entry_newsletter_no) );

    if (isset(
    $_post['date_format_m'])) {
      
    $selecteddateformat_m = (int)$_post['date_format_m'];
    } else {
      
    $currentdateformat_m str_replace('%m''mm'str_replace('%d''dd'str_replace('%y''yyyy'date_format_short)));
      
    $selecteddateformat_m array_search($currentdateformat_m$theformats);
    }
    if (isset(
    $_post['date_format_s'])) {
      
    $selecteddateformat_s = (int)$_post['date_format_s'];
    } else {
      
    $currentdateformat_s str_replace('%m''mm'str_replace('%d''dd'str_replace('%y''yyyy'date_format_short)));
      
    $selecteddateformat_s array_search($currentdateformat_s$theformats);
    }

    for (
    $i=0$n=sizeof($theformats), $dateformats=array(); $i<$n$i++) {
      
    $dateformats[$i]['id'] = $i;
      
    $dateformats[$i]['text'] = $theformats[$i];
    }

    $resendid = (isset($_post['resend_id'])) ? $_post['resend_id'] : 0;
    ?>
      <h1><?php echo heading_title?></h1>
      <table border="0" width="100%" cellspacing="2" cellpadding="2">
        <tr>
          <td width="100%" valign="top">
            <table border="0" width="100%" cellspacing="0" cellpadding="2">
              <tr>
                <td id="multiple"><table border="0" cellspacing="2" cellpadding="2">
                  <tr>
                    <td id="csv_in">
                      <div class="headinglabel"><?php echo customers_bulk_upload?></div>
                  <?php if ($action == 'add_multiple') echo $infodivcontents?>
                  <?php echo zen_draw_form('customers'filename_add_customers'''post''enctype="multipart/form-data"') . Zen_hide_session_id(). Zen_draw_hidden_field'action''add_multiple'); ?>
                        <div class="formarea"><table border="0" cellspacing="2" cellpadding="2">
                          <tr>
                            <td><div class="back mainlabel"><?php echo customers_file_import?></div><input type="file" name="bulk_upload" /></td>
                          </tr>
                          <tr>
                            <td>
                              <div class="back mainlabel"><?php echo customers_insert_mode?></div>
                              <div class="back">
                                <input type="radio" name="insert_mode" value="part" <?php echo ($insert_mode == 'part') ? 'checked="checked"' ''?>/><?php echo customers_insert_mode_valid?><br />
                                <input type="radio" name="insert_mode" value="file" <?php echo ($insert_mode == 'file') ? 'checked="checked"' ''?>/><?php echo customers_insert_mode_file?>
                              </div>
                            </td>
                          </tr>
                          <tr>
                            <td><div class="back mainlabel"><?php echo date_format_choose_multi?></div><?php echo zen_draw_pull_down_menu('date_format_m'$dateformats$selecteddateformat_m); ?></td>
                          </tr>
                          <tr>
                            <td>
                              <div style="width:350px; text-align: Right;">
                                <a href="<?php echo http_server Dir_ws_catalog?>add_customers_formatting_csv.html" target="_blank"><?php echo formatting_the_csv?></a>##<input type="submit" name="add_customers_in_bulk" value="upload" />
                              </div>
                            </td>
                          </tr>
                        </table></div>
                      </form>
                    </td>
                  </tr>
                  
                  <tr>
                    <td>
                      <div class="headinglabel"><?php echo resend_welcome_email?></div>
                  <?php if ($action == 'resend_email') echo $infodivcontents?>
                  <?php echo zen_draw_form('resend'filename_add_customers'''post''enctype="multipart/form-data"') . Zen_hide_session_id() . Zen_draw_hidden_field ('action''resend_email'); ?>
                        <div class="formarea"><table border="0" cellspacing="2" cellpadding="2">
                          <tr>
                            <td><div class="back mainlabel"><?php echo text_choose_customer?></div><div class="main"><?php echo zen_draw_pull_down_menu('resend_id'create_customer_drop_down(), $resendid); ?></div></td>
                          </tr>
                          <tr class="clearboth">
                            <td><div class="back mainlabel"><?php echo text_reset_password?></div><div class="main"><input type="checkbox" id="reset_pw" value="1" name="reset_pw" <?php echo (isset($_post['reset_pw'])) ? 'checked="checked"' ''?>/></div></td>
                          </tr>
                          <tr>
                            <td>
                              <div style="width:350px; text-align: Right;">
                                <input type="submit" name="resend" value="<?php echo button_resend?>" />
                              </div>
                            </td>
                          </tr>
                        </table></div>
                      </form>
                    </td>
                  </tr>
                </table></td>
                
                <td id="single"><div class="headinglabel"><?php echo customers_single_entry?></div><?php if ($action == 'add_single' && zen_not_null($_post['insert_x']) && zen_not_null($_post['insert_y'])) echo $infodivcontents?><?php echo zen_draw_form('customers_1'filename_add_customers'''post') . Zen_hide_session_id() . Zen_draw_hidden_field'action''add_single'); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">
                  <tr>
                    <td class="formareatitle"><?php echo category_personal?></td>
                  </tr>
                  <tr>
                    <td class="formarea"><table border="0" cellspacing="2" cellpadding="2">
    <?php
      $customers_authorization_array 
    = array( array('id' => '0''text' => customers_authorization_0),
                                              array(
    'id' => '1''text' => customers_authorization_1),
                                              array(
    'id' => '2''text' => customers_authorization_2),
                                              array(
    'id' => '3''text' => customers_authorization_3)
                                            );
    ?>
                      <tr>
                        <td class="main mainlabel"><?php echo customers_authorization?></td>
                        <td class="main"><?php echo zen_draw_pull_down_menu('customers_authorization'$customers_authorization_array$cinfo->customers_authorization); ?></td>
                      </tr>              
    <?php
      
    if (account_gender == 'true') {
    ?>
                      <tr>
                        <td class="main mainlabel" style="vertical-align:top;"><?php echo entry_gender?></td>
                        <td class="main">
                          <input type="radio" name="customers_gender" value="m" <?php echo ($cinfo->customers_gender == 'm') ? 'checked' ''?> /><?php echo male?>
                          <span class="spacer"></span>
                          <input type="radio" name="customers_gender" value="f" <?php echo ($cinfo->customers_gender == 'f') ? 'checked' ''?> /><?php echo female?>
                        </td>
                      </tr>
    <?php
      
    }
    ?>
                      <tr>
                        <td class="main mainlabel"><?php echo entry_first_name?></td>
                        <td class="main"><input size="30" name="customers_firstname" value="<?php echo $cinfo->customers_firstname?>" /></td>
                      </tr>

                      <tr>
                        <td class="main mainlabel"><?php echo entry_last_name?></td>
                        <td class="main"><input size="30" name="customers_lastname" value="<?php echo $cinfo->customers_lastname?>" /></td>
                      </tr>
    <?php
      
    if (account_dob == 'true') {
    ?>
                    <tr>
                      <td class="back mainlabel"><?php echo date_format_choose_single?></td>
                      <td class="main"><?php echo zen_draw_pull_down_menu('date_format_s'$dateformats$selecteddateformat_s); ?></td>
                      </tr>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_date_of_birth?></td>
                      <td class="main"><input size="30" name="customers_dob" value="<?php echo $cinfo->customers_dob?>" /></td>
                    </tr>
    <?php
      
    }
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_email_address?></td>
                      <td class="main"><input size="30" name="customers_email_address" value="<?php echo $cinfo->customers_email_address?>" /></td>
                    </tr> 

                  </table></td>
                </tr>
    <?php
      
    if (account_company == 'true') {
    ?>
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formareatitle"><?php echo category_company?></td></tr>
                <tr>
                  <td class="formarea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main mainlabel"><?php echo entry_company?></td>
                      <td class="main"><input size="30" name="entry_company" value="<?php echo $cinfo->entry_company?>" /></td>
                    </tr>
                  </table></td>
                </tr>
    <?php
      
    }
    ?>
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formareatitle"><?php echo category_address?></td></tr>
                <tr>
                  <td class="formarea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main label"><?php echo entry_street_address?></td>
                      <td class="main"><input size="30" name="entry_street_address" value="<?php echo $cinfo->entry_street_address?>" /></td>
                    </tr>           
    <?php
      
    if (account_suburb == 'true') {
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_suburb?></td>
                      <td class="main"><input size="30" name="entry_suburb" value="<?php echo $cinfo->entry_suburb?>" /></td>
                    </tr>
    <?php              
      
    }
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_city?></td>
                      <td class="main"><input size="30" name="entry_city" value="<?php echo $cinfo->entry_city?>" /></td>
                    </tr>                                   

                    <tr>
                      <td class="main mainlabel"><?php echo entry_post_code?></td>
                      <td class="main"><input size="30" name="entry_postcode" value="<?php echo $cinfo->entry_postcode?>" /></td>
                    </tr>
                  
                    <tr>
                      <td class="main mainlabel"><?php echo entry_country?></td>
                      <td class="main"><?php echo zen_draw_pull_down_menu('entry_country_id'zen_get_countries(), (zen_not_null($cinfo->entry_country_id) ? $cinfo->entry_country_id Show_create_account_default_country), 'onchange="this.form.submit();"'); ?></td>
                    </tr>
    <?php
      
    if (account_state == 'true') {
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_state?></td>
                      <td class="main">
    <?php
        $thezones 
    zen_prepare_country_zones_pull_down ((zen_not_null($cinfo->entry_country_id) ? $cinfo->entry_country_id Show_create_account_default_country));
        if (
    count($thezones) > 1) {
          echo 
    zen_draw_pull_down_menu('entry_zone_id'$thezones$cinfo->entry_zone_id);
          
        } else {
          
    $entry_state zen_get_zone_name($cinfo->entry_country_id$cinfo->entry_zone_id$cinfo->entry_state);
          echo 
    zen_draw_input_field('entry_state'zen_get_zone_name($cinfo->entry_country_id$cinfo->entry_zone_id$cinfo->entry_state));
        }
      }
    ?>
                      </td>
                    </tr>
                  </table></td>
                </tr>
              
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formareatitle"><?php echo category_contact?></td></tr>
                <tr>
                  <td class="formarea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main mainlabel"><?php echo entry_telephone_number?></td>
                      <td class="main"><input size="30" name="customers_telephone" value="<?php echo $cinfo->customers_telephone?>" /></td>
                    </tr>
    <?php
      
    if (account_fax_number == 'true') {
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_fax_number?></td>
                      <td class="main"><input size="30" name="customers_fax" value="<?php echo $cinfo->customers_fax?>" /></td>
                    </tr>
    <?php
      
    }
    ?>
                  </table></td>
                </tr>
              
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr><td class="formareatitle"><?php echo category_options?></td></tr>
                <tr>
                  <td class="formarea"><table border="0" cellspacing="2" cellpadding="2">
                    <tr>
                      <td class="main mainlabel"><?php echo entry_email_preference?></td>
                      <td class="main">
    <?php
      $email_pref_text 
    = ( (empty($cinfo) && account_email_preference != '1') || $cinfo->customers_email_format == 'text' ) ? True False;
      
    $email_pref_html = !$email_pref_text;
      echo 
    zen_draw_radio_field('customers_email_format''html'$email_pref_html) . '##' Entry_email_html_display '######' Zen_draw_radio_field('customers_email_format''text'$email_pref_text) . '##' Entry_email_text_display ;
    ?>
                      </td>
                    </tr>
                  
                    <tr>
                      <td class="main label"><?php echo entry_newsletter?></td>
                      <td class="main"><?php echo zen_draw_pull_down_menu('customers_newsletter'$newsletter_array, (($cinfo->customers_newsletter == '1') ? '1' '0')); ?></td>
                    </tr>
                  
                    <tr>
                      <td class="main mainlabel"><?php echo entry_pricing_group?></td>
                      <td class="main">
    <?php
      $group_array_query 
    $db->execute("select group_id, group_name, group_percentage from " Table_group_pricing);
      
    $group_array[] = array('id'=>0'text'=>text_none);

      while (!
    $group_array_query->eof) {
        
    $group_array[] = array('id'=>$group_array_query->fields['group_id'], 'text'=>$group_array_query->fields['group_name'].'##'.$group_array_query->fields['group_percentage'].'%');
        
    $group_array_query->movenext();
      }

      echo 
    zen_draw_pull_down_menu('customers_group_pricing'$group_array$cinfo->customers_group_pricing);
    ?>
                      </td>
                    </tr>
    <?php
      
    if (customers_referral_status == 2) {
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo customers_referral?></td>
                      <td class="main"><?php echo zen_draw_input_field('customers_referral'$cinfo->customers_referralzen_set_field_length(table_customers'customers_referral'15)); ?></td>
                    </tr>
    <?php
      
    }
    ?>
                    <tr>
                      <td class="main mainlabel"><?php echo entry_email?></td>
                      <td class="main"><input type="checkbox" id="send_welcome" value="1" name="send_welcome" <?php echo (isset($_post['send_welcome'])) ? 'checked="checked"' ''?>/></td>
                    </tr>
                  </table></td>
                </tr>
              
                <tr><td><?php echo zen_draw_separator('pixel_trans.gif''1''10'); ?></td></tr>
                <tr>
                  <td align="right" class="main"><?php echo zen_image_submit('button_insert.gif'image_update'name="insert"'); ?><a href="<?php echo zen_href_link(filename_customerszen_get_all_get_params(array('action')), 'nonssl'); ?>"><?php echo zen_image_button('button_cancel.gif'image_cancel); ?></a></td>
                </tr>
              </table></form></td></tr>

          </table>
        </td>
      </tr>
    </table>
    <?php
    require(dir_ws_includes 'footer.php');
    ?>
    <br />
    </body>
    </html>
    <?php
    require(dir_ws_includes 'application_bottom.php');
    ?>
    bump...

  7. #217
    Join Date
    May 2011
    Location
    Nova Scotia
    Posts
    35
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    Your still going to have the same problem if the customer decides to come off that mail list from their ZENcart login it will take them off but if they then decide to opt back in it will add the check box but not sign them back up to mailchimp.

  8. #218
    Join Date
    Apr 2006
    Posts
    67
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    Are they away to put a link in the footer to go to the sign up page of mail chimp newsletter?

  9. #219
    Join Date
    May 2011
    Location
    Nova Scotia
    Posts
    35
    Plugin Contributions
    0

    Default Re: MailChimp Newsletter Sidebox

    You could or they could sign up again with the side box but People don't always do what we would like them to do, so like other things you have anticipate what people might do. & they could click the check box to sign up again.

  10. #220
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,683
    Plugin Contributions
    123

    Default Re: MailChimp Newsletter Sidebox

    Quote Originally Posted by tnjon View Post
    Are they away to put a link in the footer to go to the sign up page of mail chimp newsletter?
    Certainly you could do this. Mailchimp gives you a hosted signup page which you can find by logging into your account and poking around. Then add this link to your includes/templates/YOUR_TEMPLATE/common/tpl_footer.php file, or make an ez page link out of it, etc.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

 

 
Page 22 of 41 FirstFirst ... 12202122232432 ... LastLast

Similar Threads

  1. v150 Newsletter Sidebox & Newsletter signup
    By meljen in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 28 Nov 2012, 09:44 PM
  2. Login page->Newsletter->Mailchimp
    By Happyworker in forum All Other Contributions/Addons
    Replies: 9
    Last Post: 23 Jun 2010, 10:41 PM
  3. Anyone know how to add field for Mailchimp to sidebox?
    By daneh in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 16 Sep 2009, 04:40 PM
  4. Adding a user to a MailChimp newsletter?
    By fabiola-and-singsing in forum General Questions
    Replies: 3
    Last Post: 16 Feb 2009, 10:07 AM
  5. Stop Sidebox header from linking - MailChimp
    By Mickmo68 in forum Addon Sideboxes
    Replies: 2
    Last Post: 21 Nov 2008, 05:54 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR