• Resolved thynccreative

    (@thynccreative)


    Hello,

    When I set a notification so send an email on “New ‘Custom post type'” it also sends the email when it is updated or submitted for review. I am looking to send the email only once when it has been published.

    I also notice in the dropdown for the custom post type it says “New ‘Custom post type'” Whereas for normal post and pages it says “New post published” adding the published at the end.

    I don’t know if this is a bug or is normal and I’m just missing something! Please help!

Viewing 15 replies - 1 through 15 (of 21 total)
  • Plugin Author bnfw

    (@voltronik)

    Hi @thynccreative,
    Thanks for your message.

    How are you creating your new custom posts? Is it via the WordPress Admin or another method?

    With regards to the labelling of the ‘New Custom Post Type’ notification, I’m going to make sure it says ‘Published’ at the end in the next version for more consistency between notifications.

    Thanks,
    Jack

    Thread Starter thynccreative

    (@thynccreative)

    Hi Jack,

    Thanks for replying so quickly. Im creating the custom post type using the following code in my theme’s functions.php:

    function governor_documents_cpt() {
    
      $labels = array(
        'name'                  => 'Governor Documents',
        'singular_name'         => 'Governor Document',
        'menu_name'             => 'Governor Documents',
        'name_admin_bar'        => 'Governor Documents',
        'archives'              => 'Item Archives',
        'attributes'            => 'Item Attributes',
        'parent_item_colon'     => 'Parent Item:',
        'all_items'             => 'All Items',
        'add_new_item'          => 'Add New Item',
        'add_new'               => 'Add New',
        'new_item'              => 'New Item',
        'edit_item'             => 'Edit Item',
        'update_item'           => 'Update Item',
        'view_item'             => 'View Item',
        'view_items'            => 'View Items',
        'search_items'          => 'Search Item',
        'not_found'             => 'Not found',
        'not_found_in_trash'    => 'Not found in Trash',
        'featured_image'        => 'Featured Image',
        'set_featured_image'    => 'Set featured image',
        'remove_featured_image' => 'Remove featured image',
        'use_featured_image'    => 'Use as featured image',
        'insert_into_item'      => 'Insert into item',
        'uploaded_to_this_item' => 'Uploaded to this item',
        'items_list'            => 'Items list',
        'items_list_navigation' => 'Items list navigation',
        'filter_items_list'     => 'Filter items list',
      );
      $capabilities = array(
        'edit_post'             => 'edit_governor_documents',
        'read_post'             => 'read_governor_documents',
        'delete_post'           => 'delete_governor_documents',
        'delete_private_posts'  => 'delete_governor_documents',
        'delete_published_posts'  => 'delete_governor_documents',
        'delete_others_posts'  => 'delete_governor_documents',
        'edit_posts'            => 'edit_governor_documents',
        'edit_others_posts'     => 'edit_other_governor_documents',
        'publish_posts'         => 'publish_governor_documents',
        'read_private_posts'    => 'read_governor_documents',
        'create_posts'          => 'create_governor_documents', 
      );
      $args = array(
        'label'                 => 'Governor Document',
        'description'           => 'Governor Documents',
        'labels'                => $labels,
        'supports'              => array( 'title'),
        'hierarchical'          => false,
        'public'                => true,
        'show_ui'               => true,
        'show_in_menu'          => true,
        'menu_position'         => 5,
        'menu_icon'             => 'dashicons-media-document',
        'show_in_admin_bar'     => true,
        'show_in_nav_menus'     => false,
        'can_export'            => true,
        'has_archive'           => true,    
        'exclude_from_search'   => true,
        'publicly_queryable'    => false,
        'capabilities'          => $capabilities,
      );
      register_post_type( 'governor_documents', $args );
    
    }
    add_action( 'init', 'governor_documents_cpt', 0 );

    Thanks,
    Michael.

    Thread Starter thynccreative

    (@thynccreative)

    Hi Jack,

    Sorry yes I am creating the custom posts via the WP-Admin.

    Thanks,
    Michael.

    Plugin Author bnfw

    (@voltronik)

    Hi @thynccreative,
    I’ve just tested and can’t replicate your issue.

    It could be potential plugin or theme conflict. Please can you make your way through this document and let me know how you get on?

    Thanks,
    Jack

    Thread Starter thynccreative

    (@thynccreative)

    Hi Jack,

    If I disable advanced custom fields pro – it works, but when enabled it emails for every update.

    Thanks,
    Michael.

    Thread Starter thynccreative

    (@thynccreative)

    Hi Jack,

    It’s if the post type has any custom fields associated with it using the ACF plugin.

    Thanks,
    Michael

    Plugin Author bnfw

    (@voltronik)

    Hi @thynccreative,
    Thanks for the additional information.

    I’m going to do some investigation and let you know what I find.

    Thanks,
    Jack

    I can verify that I have the same issue with the latest version. I also use Custom Fields Pro, so something is broken.

    Sadly it sends notifications also on scheduled posts so NDA articles are sadly spread. We have shut down this plugin until the issue has been resolved.

    this message just to be notified on follow-up answers – sorry

    Same issue here, also with ACF Pro enabled.

    Same issue here, also with ACF Pro enabled, but I do not know what ACF is involved in this issue

    Look This!!!!! log image

    Log

    Postman log

    So CRASY

    How Can I do a downgrade version of the plugin?

    Same issue with ACF Pro. You can download previous versions of the plugin here: https://www.ads-software.com/plugins/bnfw/developers/

    What I have done now, is to download 1.6.2, and write 1.6.3 in the code, so it dont get updated by mistake, and then I hope 1.6.4 will solve the issue, but I think the developer is very quiet.

Viewing 15 replies - 1 through 15 (of 21 total)
  • The topic ‘New Custom post type notification sending emails on update not just published’ is closed to new replies.