• Resolved tkwpweb

    (@tkwpweb)


    Hello,

    when i submit a post with custom post type all is fine. The Post is submitted correct. But in my Dashboard they show “No published Posts”.

    I hope you understand my bad english…

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter tkwpweb

    (@tkwpweb)

    By reading in Forums i found this solution:
    [wpuf_dashboard post_type=”custom_post_type”]

    But i need this:
    [wpuf_account post_type=”custom_post_type”] …but this shortcode is not working.

    Hello @tkwpweb,

    The custom posts are supposed to show up in the dashboard page by default. The dashboard page is a page where you can show all your custom post type posts.

    The [wpuf_account] shortcode is unable to accept any parameter. So if you want to show the custom post type post in the account page, you have to add the following custom code in your child theme’s functions.php file:

    add_filter( 'wpuf_account_sections', 'wpuf_my_page' );
    
    function wpuf_my_page( $sections ) {
    $sections = array_merge( $sections, array( array( 'slug' => 'my-page', 'label' => 'Custom Post' ) ) );
    
    return $sections;
    }
    
    add_action( 'wpuf_account_content_my-page', 'wpuf_my_page_section', 10, 2 );
    
    function wpuf_my_page_section( $sections, $current_section ) {
    
     echo do_shortcode('[wpuf_dashboard post_type="custom_post_type"]');
    
    }
    
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Problem with custom post type’ is closed to new replies.