Can’t post follow up comment

Can’t post follow up comment on thread, please advise. Auto-Registered Affiliate not getting welcome emails is the thread.

TIA

13 Responses to Can’t post follow up comment

  1. George May 16, 2017 at 4:39 pm #

    Hi Carolyn,

    You can post a new topic, or edit the description here, or give me a link to your previous topic.

    Kind regards,
    George

  2. Carolyn May 16, 2017 at 7:01 pm #

    This paste includes only the code for the Affiliates Email portion of functions.php:

    https://pastebin.com/WcVv0Bn2

  3. George May 17, 2017 at 10:34 am #

    Thanks for sharing.
    In case you are still using the custom snippet i suggested, please let me know which WooCommerce plugin version is currently installed on your site.

    Cheers,
    George

  4. Carolyn May 17, 2017 at 3:14 pm #

    WooCommerce Version 3.0.6 |

  5. George May 17, 2017 at 5:32 pm #

    Please delete the Affiliates Welcome Email snippet from functions.php and add the affiliates-welcome-email.zip file i sent you. This can be installed as any other plugin.
    Once this is activated and the other snippet is placed in your functions.php file, the feature should be ok.
    If not, please enable WordPress debugging repeat the process and check if there is anything logged in debug.log. Also make sure that your site can send emails in general, ie if after a new user registration the new user receives a welcome email message from your site.

    To enable debugging, edit your wp-config file and replace the following line:
    define('WP_DEBUG', false);
    with these lines:
    define('WP_DEBUG', true);
    define('WP_DEBUG_LOG', true);

    Finally create a new file named debug.log under your wp-content folder.

    Kind regards,
    George

  6. Carolyn May 17, 2017 at 5:35 pm #

    Where did you send the zip? I didn’t get anything emailed from you.

  7. Carolyn May 17, 2017 at 6:34 pm #

    Loading a page after editing functions.php gives me the following in the debug.log:

    [17-May-2017 18:28:04 UTC] PHP Fatal error: Cannot redeclare my_action_woocommerce_order_status_completed() (previously declared in /home/npl/acceleratingyoungminds.com/wp-content/themes/bridge-child/functions.php:76) in /home/npl/acceleratingyoungminds.com/wp-content/themes/bridge-child/functions.php on line 410

  8. Carolyn May 17, 2017 at 8:05 pm #

    The name they use for this new replacement function was the exact same as that used for the purchaser-becomes-affiliate function (from weeks ago):

    my_action_woocommerce_order_status_completed

    I changed the name of the new function to:

    email_action_woocommerce_order_status_completed

    And that brings the site back up

  9. George May 18, 2017 at 7:59 am #

    That’s because you added the auto-affiliate snippet again.

  10. Carolyn May 18, 2017 at 2:10 pm #

    I don’t think he did, after he changed the above, it worked. Now the problem I am seeing is that the email to the affiliate is not working right, the tokens I added to the notifications emails in affiliates are not showing up properly. It looks like this:

    Welcome to the AYM Families in Education Program!
    Username: [username]
    Password: [password]
    Login here

    Thanks for joining the AYM Families in Education program.

    It should be showing the username and password, also the should not be showing right? Can you help me figure out what I am doing wrong?

    You can register/buy here so you can see the issue: http://www.acceleratingyoungminds.com/product/fie-director-bundle-2/

    I sure appreciate the help!!!!

  11. Carolyn May 18, 2017 at 6:35 pm #

    Think I found the issue:

    Seems like the the plugin is apparently overriding the admin Notifications area somehow, but not processing the included shortcodes correctly.

    The email messages are coming through with “[username]” and “[password]” printed directly in the email, exactly as they are written in the plugin code.

    $subject = ‘Welcome from Accelerating Young Minds!’;
    $message = ‘Welcome to the AYM Families in Education Program!
    Username: [username]
    Password: [password]
    Login here

    Thanks for joining the AYM Families in Education program.’;

    Can you tell us how to fix this?

  12. George May 19, 2017 at 8:30 am #

    Hi,

    I’ve just sent you an updated version of Affiliates Welcome Email.
    Please deactivate and delete your current version and install the one attached instead.
    The password field is perhaps impossible to retrieve once stored in the database, because passwords are encrypted for security reasons.
    Give it a try and let me know if it works properly this time.

    Cheers,
    George