Forum Replies Created

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • in reply to: Status Change without Activation email #322114
    Anselm Peischl
    Participant

    A non-coding friend has created an integration from Forminator > TNP, where we would like to add these users as unconfirmed until an order in woocommerce has been paid and confirm it then.

    Now my idea was to hook into newsletter_user_subscribe and reset $user->status = "S" and reset it upon woocommerce_order_status_processing

    so my basic approach is add_filter("newsletter_user_subscribe", "rtr_subscriber_update", 10, 1);

    function rtr_subscriber_update($user) {
        if(is_admin()) {
            return;
        }  
        $user->status = 'S';
       return $user; <code>which results into sending out activation emails regardless of settings or</code>add_filter('newsletter_activation_email', function ($default, $user) { return false; }, 10, 2);
    

    – btw newlines dont seem to work in the forum, also I dont get the code formatting done better :/ sorry

    in reply to: Call subscriber information in other wordpress functions? #296402
    Anselm Peischl
    Participant

    Thank you for your reply, is the very same possible in combination with the hash to add further security?

Viewing 2 posts - 1 through 2 (of 2 total)