Results 1 to 8 of 8
  1. #1
    Join Date
    Jun 2009
    Posts
    33
    Plugin Contributions
    0

    Default Disable Welcome Email Not Working

    I tried the fix here that was intended to disable the welcome email, but it still sends: http://www.zen-cart.com/forum/showth...+welcome+email

    I use ZC 1.5.1. Any other ideas as to what I can do? I am trying to cut down on the emails being sent from our server as we do a one-week only sale that gets 5,000+ orders. Last year we sent too much email out (welcome and order confirmation) that our server was blacklisted for possible spammers.


    The actual email is sent from the file:
    /includes/modules/create_account.php

    to the customer:
    PHP Code:
    // send welcome email
    zen_mail($name, $email_address, EMAIL_SUBJECT, $email_text, STORE_NAME, EMAIL_FROM, $html_msg, 'welcome');



    I tried commenting it out and even deleting it and it still sends. Thank you for ANY help you can offer.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: Disable Welcome Email Not Working

    Which payment modules do you use? ... cuz if you're using PayPal Express Checkout it will send welcome emails too whenever it creates a customer record as part of a customer paying with EC.
    .
    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Jun 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Disable Welcome Email Not Working

    I do have PP EC enabled. It will send to everyone - regardless of whether or not they create an account at first visit or checkout? I am getting the email with just creating an account. Can it be disabled?

  4. #4
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: Disable Welcome Email Not Working

    You can disable it by commenting-out the zen_mail call in that section of the code, in the paypalwpp.php payment module file.
    .
    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Jun 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Disable Welcome Email Not Working

    Quote Originally Posted by DrByte View Post
    You can disable it by commenting-out the zen_mail call in that section of the code, in the paypalwpp.php payment module file.
    I see several places where the zen_mail function is listed, but I cannot determine which one sends the welcome email. Can you point me in the right direction?

  6. #6
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: Disable Welcome Email Not Working

    So I went looking in the code, and I see that there's an even easier way to deal with it, from v151 onward:

    In your language files (create_account.php), simply change the define for EMAIL_SUBJECT from whatever it currently is (probably "welcome to".STORE_NAME or such), to 'n/a', like this:
    Code:
    define('EMAIL_SUBJECT', 'n/a');
    And for admin-copies of those emails, in email_extras, do similarly:
    Code:
    define('SEND_EXTRA_CREATE_ACCOUNT_EMAILS_TO_SUBJECT', 'n/a');
    This way you don't need to alter the code in the "module" files.
    .
    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  7. #7
    Join Date
    Jun 2009
    Posts
    33
    Plugin Contributions
    0

    Default Re: Disable Welcome Email Not Working

    Quote Originally Posted by DrByte View Post
    So I went looking in the code, and I see that there's an even easier way to deal with it, from v151 onward:

    In your language files (create_account.php), simply change the define for EMAIL_SUBJECT from whatever it currently is (probably "welcome to".STORE_NAME or such), to 'n/a', like this:
    Code:
    define('EMAIL_SUBJECT', 'n/a');
    And for admin-copies of those emails, in email_extras, do similarly:
    Code:
    define('SEND_EXTRA_CREATE_ACCOUNT_EMAILS_TO_SUBJECT', 'n/a');
    This way you don't need to alter the code in the "module" files.
    That did not work.

  8. #8
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: Disable Welcome Email Not Working

    Okay, then maybe you're using altered code or not actually v151.

    You can comment-out this line:
    Code:
    if (trim(EMAIL_SUBJECT) != 'n/a') zen_mail($paypal_ec_payer_info['payer_firstname'] . " " . $paypal_ec_payer_info['payer_lastname'], .....
    .
    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. I do not receive a welcome email
    By Ms_X in forum General Questions
    Replies: 1
    Last Post: 26 Jan 2011, 02:02 PM
  2. Line breaks in welcome email aren't working
    By vivani in forum General Questions
    Replies: 1
    Last Post: 13 Jul 2010, 09:46 AM
  3. welcome email and emailing from admin not working
    By Rickwilliams in forum General Questions
    Replies: 7
    Last Post: 3 Nov 2009, 12:25 AM
  4. "\n" in welcome email not working
    By jensurge in forum General Questions
    Replies: 1
    Last Post: 2 Dec 2008, 12:10 AM

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