Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 26
  1. #11
    Join Date
    Jul 2012
    Posts
    16,734
    Plugin Contributions
    17

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Have you tried commenting out line 324 of includes/functions/functions_osh_update.php?
    Code:
    // $mail->addCustomHeader('Auto-Submitted: auto-generated');
    This is a change captured in Zen Cart 1.5.7 to address email failure/flagging as Spam.

    Otherwise might suggest starting to troubleshoot the function by adding some debugging code.

    Another place that may need commenting (as identified in that file) is at line 343 based on the comment at line 342.

    And said that the email is not logged in the archive? There is code that is supposed to get executed if there is a $to_address ($send_extra_emails_to (where that does not include new-line characters and the order_status_extra "module" hasn't been identified as one to be skipped and a few other "basic" conditions have been met to allow sending the order status update messages)).
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  2. #12
    Join Date
    May 2005
    Location
    England
    Posts
    626
    Plugin Contributions
    0

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by mc12345678 View Post
    Have you tried commenting out line 324 of includes/functions/functions_osh_update.php?
    Code:
    // $mail->addCustomHeader('Auto-Submitted: auto-generated');
    This is a change captured in Zen Cart 1.5.7 to address email failure/flagging as Spam.

    Otherwise might suggest starting to troubleshoot the function by adding some debugging code.

    Another place that may need commenting (as identified in that file) is at line 343 based on the comment at line 342.

    And said that the email is not logged in the archive? There is code that is supposed to get executed if there is a $to_address ($send_extra_emails_to (where that does not include new-line characters and the order_status_extra "module" hasn't been identified as one to be skipped and a few other "basic" conditions have been met to allow sending the order status update messages)).
    Thanks for your reply. I only have 190 lines in that file, but maybe I should look for the github for 1.57? I will take a look and try that. I did try developer tool kit to see if that line was anywhere else (in 1.56c) but didn't show any results.
    Last edited by HeathenMagic; 8 Aug 2019 at 03:45 PM.

  3. #13
    Join Date
    Jul 2012
    Posts
    16,734
    Plugin Contributions
    17

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by HeathenMagic View Post
    Thanks for your reply. I only have 190 lines in that file, but maybe I should look for the github for 1.57? I will take a look and try that. I did try developer tool kit to see if that line was anywhere else (in 1.56c) but didn't show any results.
    Arghh. I quoted the wrong file. Additionally, thought about it some more that it doesn't seem like it would be the issue because other messages are successful. The file I should have referenced for commenting out anything was the includes/functions/functions_email.php file.

    Seeing as the issue appears to be with updates (intended to be executed by includes/functions/functions_osh_updates.php, there seems that there might be something amiss with the file or there is something in it or made available for subsequent messaging that is not working.

    Some other thoughts for trial (if not already attempted) is to set for text only messages. There may be an issue with the email template file for updates.

    Part of what I might suggest looking at (perhaps a wild goose chase) would be the file permissions for each of these last two files as compared to others in the same directory. The email template (for html messages) would be expected to be found in the emails sub-directory off of the catalog folder.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  4. #14
    Join Date
    May 2005
    Location
    England
    Posts
    626
    Plugin Contributions
    0

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by mc12345678 View Post
    Arghh. I quoted the wrong file. Additionally, thought about it some more that it doesn't seem like it would be the issue because other messages are successful. The file I should have referenced for commenting out anything was the includes/functions/functions_email.php file.

    Seeing as the issue appears to be with updates (intended to be executed by includes/functions/functions_osh_updates.php, there seems that there might be something amiss with the file or there is something in it or made available for subsequent messaging that is not working.

    Some other thoughts for trial (if not already attempted) is to set for text only messages. There may be an issue with the email template file for updates.

    Part of what I might suggest looking at (perhaps a wild goose chase) would be the file permissions for each of these last two files as compared to others in the same directory. The email template (for html messages) would be expected to be found in the emails sub-directory off of the catalog folder.
    Thats okay, I just found it (was using tool kit with the comment lines, my bad). But I changed those two lines by commenting and still the same. I will get back to you about the other suggestions. I do seem to get the strange errors that nobody else gets :-/ !

  5. #15
    Join Date
    May 2005
    Location
    England
    Posts
    626
    Plugin Contributions
    0

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by mc12345678 View Post
    Arghh. I quoted the wrong file. Additionally, thought about it some more that it doesn't seem like it would be the issue because other messages are successful. The file I should have referenced for commenting out anything was the includes/functions/functions_email.php file.

    Seeing as the issue appears to be with updates (intended to be executed by includes/functions/functions_osh_updates.php, there seems that there might be something amiss with the file or there is something in it or made available for subsequent messaging that is not working.

    Some other thoughts for trial (if not already attempted) is to set for text only messages. There may be an issue with the email template file for updates.

    Part of what I might suggest looking at (perhaps a wild goose chase) would be the file permissions for each of these last two files as compared to others in the same directory. The email template (for html messages) would be expected to be found in the emails sub-directory off of the catalog folder.
    Thanks again for your help. I tried the text only and similar option in configuration > email , in conjuntion with the email template for order status, and changing permissions and reuploading stock file from 1.55c .

    I am wondering if it is due to me not using the order status much as I use a company that send the email updates via their own email system. As I say, that ended the past week hence I was trying to use the normal way of updating manually.

    I can see on the 17th I did a partial refund and an archive of order status is there, then on the evening of the 17th I upgraded to 1.55c and not more order statuses since. Not sure if the new version perhaps has a spam / filter or sessions things based on me not using order status much at all. Bit of a longshot, thinking out loud kind of thing.

  6. #16
    Join Date
    Jul 2012
    Posts
    16,734
    Plugin Contributions
    17

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by HeathenMagic View Post
    Thanks again for your help. I tried the text only and similar option in configuration > email , in conjuntion with the email template for order status, and changing permissions and reuploading stock file from 1.55c .

    I am wondering if it is due to me not using the order status much as I use a company that send the email updates via their own email system. As I say, that ended the past week hence I was trying to use the normal way of updating manually.

    I can see on the 17th I did a partial refund and an archive of order status is there, then on the evening of the 17th I upgraded to 1.55c and not more order statuses since. Not sure if the new version perhaps has a spam / filter or sessions things based on me not using order status much at all. Bit of a longshot, thinking out loud kind of thing.
    Perhaps contrary to popular thought, the software is not out to get you. :) I think in this last paragraph is perhaps the identification of what "initiated" the issue, the question remains, but why... what is different in this installation compared to a default installation of the same base software.

    One change between earlier versions of 1.5.6 and 1.5.6c is that the load sequence of functions_osh_update.php was modified.

    Could you please take a look in admin/includes/auto_loaders/config.core.php and search for:
    Code:
    $autoLoadConfig[40]
    and provide the list of results leaving them in the order found?
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  7. #17
    Join Date
    May 2005
    Location
    England
    Posts
    626
    Plugin Contributions
    0

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Haha yes that is my paranoia showing! Certainly, I will post the results for you
    Last edited by HeathenMagic; 9 Aug 2019 at 08:35 AM.

  8. #18
    Join Date
    May 2005
    Location
    England
    Posts
    626
    Plugin Contributions
    0

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by HeathenMagic View Post
    Haha yes that is my paranoia showing! Certainly, I will post the results for you
    PHP Code:
    *
     */
      
    $autoLoadConfig[40][] = array('autoType'=>'require',
                                    
    'loadFile'=> DIR_FS_CATALOG DIR_WS_FUNCTIONS 'functions_osh_update.php');
      
    $autoLoadConfig[40][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_general_funcs.php');
      
    $autoLoadConfig[40][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_tlds.php');
    /**
     * Breakpoint 50.
     *
     * require('includes/init_includes/init_cache_key_check.php');
     *
     */
      
    $autoLoadConfig[50][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_cache_key_check.php');
    /**
     * Breakpoint 60.
     *
     * require('includes/init_includes/init_sessions.php');
     *
     */
      
    $autoLoadConfig[60][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_sessions.php');
    /**
     * Breakpoint 65.
     *
     * require('includes/init_includes/init_languages.php');
     * Expecting nothing loaded before init_sanitize to require $_POST/$_GET sanitization.
     */
      
    $autoLoadConfig[65][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_languages.php');
    /**
     * Breakpoint 70.
     *
     * require('includes/init_includes/init_sanitize.php');
     *
     */
      
    $autoLoadConfig[70][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_sanitize.php');
    /**
     * Breakpoint 80.
     *
     * require('includes/init_includes/init_templates.php');
     *
     */
      
    $autoLoadConfig[80][] = array('autoType'=>'init_script',
                                    
    'loadFile'=> 'init_templates.php');
    /**
     * Breakpoint 90.
     *
     * $zc_products = new products();
     * require(DIR_WS_FUNCTIONS . 'localization.php');
     *
     */
      
    $autoLoadConfig[90][] = array('autoType'=>'classInstantiate',
                                    
    'className'=>'products',
                                    
    'objectName'=>'zc_products');
      
    $autoLoadConfig[90][] = array('autoType'=>'require',
                                     
    'loadFile'=> DIR_WS_FUNCTIONS 'localization.php');
    /**
     * Breakpoint 100.
     *
     * $messageStack = new messageStack();
     *
     */
      
    $autoLoadConfig[100][] = array('autoType'=>'classInstantiate',
                                     
    'className'=>'messageStack',
                                     
    'objectName'=>'messageStack');
    /**
     * Breakpoint 120.
     *
     * require('includes/init_includes/init_special_funcs.php');
     *
     */
      
    $autoLoadConfig[120][] = array('autoType'=>'init_script',
                                     
    'loadFile'=> 'init_special_funcs.php');

    /**
     * Breakpoint 130.
     *
     * require('includes/init_includes/init_category_path.php');
     *
     */
      
    $autoLoadConfig[130][] = array('autoType'=>'init_script',
                                     
    'loadFile'=> 'init_category_path.php');
    /**
     * Breakpoint 150.
     *
     * require('includes/init_includes/init_admin_auth.php');
     *
     */
      
    $autoLoadConfig[150][] = array('autoType'=>'init_script',
                                     
    'loadFile'=> 'init_admin_auth.php');
    /**
     * Breakpoint 160.
     *
     * require(DIR_FS_CATALOG . DIR_WS_FUNCTIONS . 'audience.php');
     *
     */
      
    $autoLoadConfig[160][] = array('autoType'=>'require',
                                     
    'loadFile'=> DIR_FS_CATALOG DIR_WS_FUNCTIONS 'audience.php');
    /**
     * Breakpoint 170.
     *
     * require('includes/init_includes/init_admin_history.php');
     *
     */
      
    $autoLoadConfig[170][] = array('autoType'=>'init_script',
                                     
    'loadFile'=> 'init_admin_history.php');
    /**
     * Breakpoint 180.
     *
     * require('includes/init_includes/init_html_editor.php);
     *
     */

      
    $autoLoadConfig[180][] = array('autoType'=>'init_script',
                                     
    'loadFile'=> 'init_html_editor.php');
    /**
     * Breakpoint 181.
     *
     * require('includes/init_includes/init_errors.php');
     *
     */
      
    $autoLoadConfig[181][] = array('autoType'=>'init_script',
                                     
    'loadFile'=> 'init_errors.php'); 

  9. #19
    Join Date
    Jul 2012
    Posts
    16,734
    Plugin Contributions
    17

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Because there are some spaces missing to support insertion of debug information, I am providing the below debug information starting from lower in the file to support line numbers. Line numbers given later in the file will be moved down by the insertion of code earlier in the file.

    Beginning at line 160, insert the following which will move the if statement down.
    Code:
    trigger_error('send_extra_to: '. print_r($send_extra_emails_to, true), E_USER_WARNING);
    Then at line 155 replace the blank line with:
    Code:
    trigger_error('send_extra_init: '. print_r($send_extra_emails_to, true), E_USER_WARNING);
    At line 139, replace the blank line with:
    Code:
    trigger_error('notify_customer: '. print_r($notify_customer, true), E_USER_WARNING);
    At line 101, replace the blank line with:
    Code:
    trigger_error('notify_customer_init: '. print_r($notify_customer, true), E_USER_WARNING);
    At line 86, insert (moving the if statement down):
    Code:
    trigger_error('pre_test: '. print_r($orders_new_status, true). ' current: '. print_r($orders_current_status, true). ' email: '. print_r($email_message, true), E_USER_WARNING);
    At line 60, insert (moving the else statement down):
    Code:
    trigger_error('skip send', E_USER_WARNING);
    Try changing status a time or two and check the logs folder. Each time the order status update file is executed by processing a new action (basically) a mydebug log is expected to be created. There are cases where more than one per execution will be generated, but let's address that later.

    Now, you can post the contents of the file(s), but... please obscure the admin directory (as I expect it to be included in the file when performing an admin status change), also obscure any personal information associated with the email that would be generated. Please use some "obvious" obfuscation. E.g. admin, some place, some name.

    Suggest posting the most recent of those files and then can recommend other actions. If there is no file generated, that would be good to know as well.

    May I also suggest possibly making a backup of the file before making all of the above edits so that it may be easier to remove them otherwise work from the last code change to the first to restore the file.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  10. #20
    Join Date
    May 2005
    Location
    England
    Posts
    626
    Plugin Contributions
    0

    Default Re: Order Status Email recently not sending (no copy or customer getting notification

    Quote Originally Posted by mc12345678 View Post
    Because there are some spaces missing to support insertion of debug information, I am providing the below debug information starting from lower in the file to support line numbers. Line numbers given later in the file will be moved down by the insertion of code earlier in the file.

    Beginning at line 160, insert the following which will move the if statement down.
    Code:
    trigger_error('send_extra_to: '. print_r($send_extra_emails_to, true), E_USER_WARNING);
    Then at line 155 replace the blank line with:
    Code:
    trigger_error('send_extra_init: '. print_r($send_extra_emails_to, true), E_USER_WARNING);
    At line 139, replace the blank line with:
    Code:
    trigger_error('notify_customer: '. print_r($notify_customer, true), E_USER_WARNING);
    At line 101, replace the blank line with:
    Code:
    trigger_error('notify_customer_init: '. print_r($notify_customer, true), E_USER_WARNING);
    At line 86, insert (moving the if statement down):
    Code:
    trigger_error('pre_test: '. print_r($orders_new_status, true). ' current: '. print_r($orders_current_status, true). ' email: '. print_r($email_message, true), E_USER_WARNING);
    At line 60, insert (moving the else statement down):
    Code:
    trigger_error('skip send', E_USER_WARNING);
    Try changing status a time or two and check the logs folder. Each time the order status update file is executed by processing a new action (basically) a mydebug log is expected to be created. There are cases where more than one per execution will be generated, but let's address that later.

    Now, you can post the contents of the file(s), but... please obscure the admin directory (as I expect it to be included in the file when performing an admin status change), also obscure any personal information associated with the email that would be generated. Please use some "obvious" obfuscation. E.g. admin, some place, some name.

    Suggest posting the most recent of those files and then can recommend other actions. If there is no file generated, that would be good to know as well.

    May I also suggest possibly making a backup of the file before making all of the above edits so that it may be easier to remove them otherwise work from the last code change to the first to restore the file.
    Thanks for this, I am just trying now but no logs so far. But I will check php-fpm and switch off temporarily, and maybe error reporting is set to strict or along those lines. I am getting other logs before so I hope I can figure out how to enable warnings

 

 
Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Sending order notification email - not the whole order
    By liderbug in forum General Questions
    Replies: 5
    Last Post: 25 Mar 2011, 03:44 AM
  2. Product notification email, not sending as html
    By AvenueBeads in forum General Questions
    Replies: 2
    Last Post: 3 Sep 2010, 03:15 AM
  3. change order status but do not want to send customer email
    By jrf in forum Managing Customers and Orders
    Replies: 6
    Last Post: 10 May 2009, 09:40 PM

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