You can do that by using category parameter in the wp_query
change the line which looks like this
$blog_query = new WP_Query( array( 'post_type' => 'post', 'paged' => $paged ) );
to
$blog_query = new WP_Query( array( 'post_type' => 'post', 'paged' => $paged, 'cat' => 4 ) );
// Here ‘4’ is the id of category you want to show, whereas you can also use the category name
For details see this link: http://codex.wordpress.org/Class_Reference/WP_Query#Category_Parameters
Related Posts:
- Categories Template Assistance
- Use template for posts with a particular category grandparent
- How to show single category archive
- How to pick the default selected value in wordpress dropdown?
- I’m trying to create an array with a foreach loop, but the array only stores the last item [closed]
- Function Reference Documenting Template Tags for use in Custom Theme Templates?
- Create page template via functions.php?
- Need help with pagination
- pass html code to worpdress
- I need to display posts in subcategory beside posts in main category
- Polylang and template files
- Showing the project type in HREF
- why is this content-template not showing any of my blog-entries?
- Weird problem happening with custom taxonmy when creating/updating posts
- How to display user nickname (not display name) in PHP template?
- Custom Template 404 for specific custom post type
- Multiple choice in a custom taxonomy
- An unwanted inline style is added to my body tag
- How to properly insert a link to a template in WordPress?
- Custom category code not showing all posts
- Displaying theme options in css
- Custom field value not saving when it contains a URL?
- Creating bulk posts with Youtube videos
- Category Thumbnail Display – How to display ONLY the main Category
- Where do posts get the sidebar from?
- Random Default Avatar Function
- Automatically add custom CSS to new posts using a category template
- Hide wordpress field if data is empty in post!
- Render ninja form inside markup
- Change the site tagline (or similar) based on current page
- hover image appears below placeholder instead of overlayed
- combine Code 1 with Code 2
- Trouble creating conditional PHP for nav menu items with children for custom Walker
- get current product name in functions.php
- Setting custom canonical urls
- Only show search results with if current date is between two dates?
- database interactions using OOP
- Customizer: Output default value in Customizer CSS
- How to add just one specific page to widget without plugin?
- Remove one value in dismissed_wp_pointers?
- get post based on category chosen in drop down – The ajax method
- How to use transient in this code for related post?
- create a select input with menus created on a custom options page
- Taxonomy linked to pages
- How can I load a PHP page without using a Template?
- Creating a related post section based on similar categories
- Swapping wp_dropdown_categories function with wp_category_checklist
- Create another “Display Site Title and Tagline” checkbox, “Header Text Color” setting and control
- Accessing data from a non-WP database/table within a page content
- WordPress blog post url on category page
- how could I load a different template part by page
- Changing layout with wp_customise
- WP dynamic featured image – Can’t get second featured image url
- Converting HTML Template to WordPress Theme
- Extending the WP_Widget_Text class
- Proper syntax or method for keeping url in modified isotope / category links
- Filter Select results based on selection
- creating a second image attachment template?
- Selectbox in admin panel function linking to CSS
- Mass update excerpt
- Can I install/embed WordPress on a ‘single page’?
- What is an equivalent of single_cat_title for getting the slug of the category?
- Issue adding sub category programmatically
- How can I get a single php file that is the equivalent of an existing WordPress page?
- How to check if a meta value has already been assigned to any user?
- How to hide products that do not have an image from a slider carousel for an ecommerce webpage?
- How to exclude category ID from Looper in WordPress
- Add a specific part of current category page url to shortcode
- how do I get a specific post from a post with a subcategory in WP
- Get and insert order email address to the PHP template inside HTML text
- Customize Theme comment template to Insert VoteUp and VoteDown buttons
- filter default query to show just selected level of child pages in wordpress
- Custom search results page not working with empty search
- WP grandchild categories in nested ul li
- Retrieve $_POST data submitted from external URL in WordPress(NOT API)
- Grab posts by multiple categories
- Pass Category Name, Description and Photo into variables to pass to jQuery
- I have a problem in the order of enqueues while enqueuing stylesheets and scripts for a specific page in my function.php
- How to fetch products with the price in a page on woocommerce using a form or live search with php
- Move category description below post list in blog
- Trying to build simple deposit code that hooks into woocommerce
- code is skipping a div
- Applying A Category to Existing Posts Where Page Title Matches Regex
- Issues getting PHP to display in category pages
- Get page that displays all children of taxonomy parent
- Add New User, extra fields which are required?
- user_profile_update_errors hook not executing
- Send an email to specific adress when button is clicked?
- Customizer: active_callback and sanitize_callback incompatibility?
- Saving and Restoring a Canvas on A Individual User Basis
- Redirect specific user role to specific site after login?
- Send multiple attachments with wp_mail in PHP
- WordPress admin pointers tour bug?
- selected option if current category is the value
- custom url rewrite for wordpress
- Extend plugin Class through functions.php
- Change title only in dynamic page
- get_template_part based upon post’s category
- How to add a do_action on refreshing of WP customizer?
- Customize position of social icons in upme plugin [closed]