• Resolved dez82

    (@dez82)


    Hi, Tienda basic theme is not working for me. Woocommerce products filter in backend shows “no products found” or “invalid post type”. Is there a way to fix it ? And is the full version of this theme have the same issue ? Thanks Roman

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi dez82,
    If you paid for it why don’t you contact the developer?

    Thread Starter dez82

    (@dez82)

    Developer linked to this forum for questions.
    Tienda Basic is free theme

    The problem is with the pre_get_post filter in functions.php. It should look like this:

    add_filter( 'pre_get_posts', 'bavotasan_search' );
    /**
     * This function modifies the main WordPress query to include an array of
     * post types instead of the default 'post' post type.
     *
     * @param object $query  The original query.
     * @return object $query The amended query.
     */
    function bavotasan_search( $query ) {
    	if ( ! is_admin() && $query->is_search && $query->is_main_query() )
    		$query->set( 'post_type', array( 'post' ) );
    
        return $query;
    }

    Gonna put a fix out in the next release.

    Thread Starter dez82

    (@dez82)

    Great !
    This is working perfect !

    Thanks man !

    Good luck !!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Products filter’ is closed to new replies.