• Resolved skumar1st

    (@skumar1st)


    Hello Team,

    Your plugin is good and customer expectation is high when any product good.

    Post Grid block need filter with 2 option. Suppose want to list all post from ABC category and from particular specific city name, in this case no any method in your plugin. Either I have to select category or location that is absolutely not satisfy requirement.

    But other PostGrid plugin has this option.

    This is really basic requirement and already given feedback few month back but still not updated.

    Please help.

    • This topic was modified 3 years, 8 months ago by skumar1st.
Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Team Brainstorm Force

    (@brainstormteam)

    Hello @skumar1st ,

    We’re glad you loved our plugin. ??

    Regarding your query, you can achieve the display post from the specific category by modifying the query args of the Post block through our Filter/Action hook doc.

    Please refer to this document.

    I hope you understand. Please let me know if you need any help from us.

    Regards,
    Sweta

    Thread Starter skumar1st

    (@skumar1st)

    Thanks for reply.

    Could you please explore, how I can retrieve post from one specific category and one specific taxonomy location?

    Thanks.

    Plugin Support Team Brainstorm Force

    (@brainstormteam)

    Hello @skumar1st ,

    If you want to display the post from the specific category by name, you can use the following filter:

    //display post from specific category by name.
    function filter_post_query( $query_args, $attributes) {
        // cat-1 is the category name.
        $query_args['category_name'] = 'cat-1';
        return $query_args;
    }
    add_filter( 'uagb_post_query_args_grid', 'filter_post_query', 10, 2 );

    Regarding your second requirement, please use the following filter. You can directly pass the args array to $query_args like this

    $query_args = array(
        'post_type' => 'post',
        'tax_query' => array(
            'relation' => 'OR',
            array(
                'taxonomy' => 'category',
                'field'    => 'slug',
                'terms'    => array( 'quotes' ),
            ),
            array(
                'taxonomy' => 'post_format',
                'field'    => 'slug',
                'terms'    => array( 'post-format-quote' ),
            ),
        ),
    );

    Also, please refer to this link.

    I hope that helps.

    Plugin Support Team Brainstorm Force

    (@brainstormteam)

    Hello @skumar1st ,

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – if you have any further questions, you can start a new thread.

    Thank you!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘2 different taxonomy in Post Grid’ is closed to new replies.