0

I have a page that I would like to show one posts from just one specific category. I'd then like a function to search the posts within this one category on just this page. I don't mind how it's searchable tag or otherwise, but I want to only bring up seatch results from that one specific category.

Thanks

0

This would help you to fetch a single post from a specific category.

$args = array('post_type' => 'post', 'posts_per_page'=> 1, 'cat' => get_cat_ID('Category Name'));

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.