• Resolved generalmemetics

    (@generalmemetics)


    Hi, I use Jetpack for Publicize on https://www.fabulistmagazine.com. I have several categories — “stories,” “art galleries,” “fabulist news,” “reviews,” etc.

    Irksomely, the ONLY category that JetPack Publicize will autopost is the “Fabulist News” category. If a post is categorized as “Fabulist News,” it automatically posts to Twitter, Facebook and LinkedIn.

    Every other post in any other category gets completely ignored, Publicize will resolutely fail to post it every time.

    I’ve looked at all the settings in both social media and JetPack, and am coming up blank. Any advice?

    —?Josh

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Jay

    (@bluejay77)

    Hi @generalmemetics,

    By default, Publicize is only triggered when you publish a new post. You can, however, extend this to other Custom Post Types. You have 2 options to add Publicize Support to a Custom Post Type:

    1. You can add Publicize support to an existing post type thanks to the add_post_type_support() function. To do so, add the following code to a functionality plugin:

    add_action('init', 'my_custom_init');function my_custom_init() {
        add_post_type_support( 'product', 'publicize' );
    }

    You’ll need to replace “product” with your Custom Post Type name.

    2. You can add Publicize support when registering the post type:

    // Register Custom Post Type
    function jetpackme_custom_post_type() {
     
     
        $labels = array(
            'name'      => _x( 'Products', 'Post Type General Name', 'text_domain' ),
        );
        $args = array(
            'label'     => __( 'product', 'text_domain' ),
            'supports'  => array( 'title', 'editor', 'publicize', 'wpcom-markdown' ),
        );
        register_post_type( 'product', $args );
     
    }
    // Hook into the 'init' action
    add_action( 'init', 'jetpackme_custom_post_type', 0 );

    You can read more about using the Publicize feature with custom post types here:

    https://jetpack.com/support/publicize/

    I hope that helps! Let us know if you have further questions.

    Best Regards,

    Jay

    Thread Starter generalmemetics

    (@generalmemetics)

    Hi Jay, thank you so much! I will look at this, but, you should know that I am not using custom-post types. Just regular posts. What matters is the category of the posts.

    In other words, post_type=post, but the taxonomy is the deciding factor. Publicize will ONLY create social posts for category&tag_id=158 … no other category works for post_type=post.

    Does that make sense? In other words, Publicize is ignoring posts that have categories other than ID=158.

    —?Josh

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Publicize only auto-posts certain categories’ is closed to new replies.