Thanks @elliot
The way I solved it is to place the add_action and call to init the plugin from the theme’s functions.php and then use the above code to begin the email subscription process.
Hi
I am running into this exact issue. I tried the above suggestions but it seems that the email plugin does not hook into ‘acf/save_post’.
This is what I have:
add_action( 'acf/save_post','process_subscriptions', 20);
and
public function process_subscriptions($post_id) {
$settings = incsub_sbe_get_settings();
// If this is just a revision, don't send the email.
if ( wp_is_post_revision( $post_id ) )
return;
if(in_array(get_post_type($post_id), $settings['post_types']))
$this->send_mails( array( $post_id ) );
}
Nothing happens, even if I put a exit code in the function, the WP still just goes through without ever calling this function.
Any ideas? Again this is inside a plugin.
Thanks