• Resolved fergusga1815

    (@fergusga1815)


    Is there any option or feasibility to use this plugin to automatically output to a page for a specific post type i.e. product when a product is added/updated/removed

    The output on the page would be grouped by date and category for each product display:

    action (add/update/remove – product name

Viewing 1 replies (of 1 total)
  • Plugin Author PickPlugins

    (@pickplugins)

    Sorry, there is only individual option to display change log automatically under post.

    If you can write code, there is shortcode available, you can use filter hook to display under any specific post type.
    [awesome_changelog id="123"]

    Please try this code.

    
    
    function ac_display_changelog_postype_function( $content ){
    
        $allowed_post_type = array('post','product');
    
        if( !in_array(get_post_type(), $allowed_post_type) ) return $content;
    
        $current_post_id 	= get_the_ID();
        $product_changelog 	= get_post_meta( $current_post_id, 'product_changelog', true );
        $ac_display_reverse 	= get_post_meta( $current_post_id, 'ac_display_reverse', true );
        
    
        if( ! empty( $product_changelog ) ) {
    
            $content .= do_shortcode("[awesome_changelog id=$current_post_id]");
        }
        
        return $content;
    }
    add_filter( 'the_content', 'ac_display_changelog_postype_function' );
    
    

    Regards

Viewing 1 replies (of 1 total)
  • The topic ‘Auto Populate’ is closed to new replies.