Here is solution…please try this stuff……
<?php
/**
* The template for displaying all pages.
*
* This is the template that displays all pages by default.
* Please note that this is the WordPress construct of pages
* and that other 'pages' on your WordPress site will use a
* different template.
*
* @package WordPress
* @subpackage Twenty_Twelve
* @since Twenty Twelve 1.0
*/
get_header(); ?>
<?php
$post = $wp_query->post;
if ( in_category('11') ) {
include(TEMPLATEPATH . '/single_our_services.php');
}
elseif ( in_category('44') ) {
include(TEMPLATEPATH . '/single_rugged_product.php');
}
elseif ( in_category('50') ) {
include(TEMPLATEPATH . '/team_leader.php');
}
elseif ( in_category('50') ) {
include(TEMPLATEPATH . '/saas_maker.php');
}
?>
<?php //get_sidebar(); ?>
<?php get_footer(); ?>
Related Posts:
- Change “Enter Title Here” help text on a custom post type
- How do you use orderby with meta_query in WordPress 3.1?
- Linking Two Post Types
- How can I change the admin search posts fields?
- Creating conditional blocks for WordPress Gutenberg
- Random post, once per day
- Prevent Google from indexing custom post types?
- How to display regular posts & custom post types that fall under a category using just the generic category template?
- Remove Trash / Delete option for Custom Post Type / Taxonomy
- How to filter custom post types by custom category taxonomy
- expire wordpress user posts
- Removing base slug from hierarchical custom post type
- WP_Query to loop a Custom Field, Custom Post Types do not show
- Custom taxonomy & post slug permalink
- sort events based on event date custom field
- Getting arguments for register_post_type from a plugin generated post type
- How can I get the last posts by user role?
- Limit taxonomy results to a single cpt
- Redirect to post with only post ID in the URL vs post_type/post ID
- Custom-post-type-archive: posts sorted/filtered by year?
- Relationship between two taxonomies and a custom post type [closed]
- Sharing a custom taxonomy with Multiple custom post types
- next_post_link on custom taxonomy
- Show Two custom Post type and their posts on category page
- WordPress nl2br is not converting newline to html line break when saving metabox value
- Change Permalink Structure for Tag.php template
- Metadata for a taxonomy – is there any WordPress way of doing this?
- Remove post type slug of all post types from permalinks
- Calculate all custom field values in the post loop
- Custom page sidebar using Template dropdown box
- Role scoping for contributors down to the field level
- I would like to have different styles for my posts based on the content of each post
- Separate custom categories from default category
- Converting the_content string to an array?
- How can I make the slug of the taxonomy also the slug of the custom post
- Assign same parrent Page to pages AND custom post types
- How to list custom taxonomies in the back end
- How do I display the grand child items of a taxonomy term?
- Top Level pages in wordpress giving 404, but child pages working fine
- Query posts with double taxonomy
- CPT category hierarchy
- How To Import CPT With Only Few TEXT ACF Fields From Front End?
- Get only used meta_values
- Getting 400 Bad Request on AJAX Call
- Remove Quick edit for custom post type?
- WordPress custom slug rewrite
- How do I create an overview page with custom calculations from a post-type?
- Not sure why this template for custom post type posts isn’t displaying anything. What’s missing?
- Creating two loops based on different logic
- Not able to export large no. of posts in csv
- How to show my post type TEAM in dynamic way?
- Set parent for custom post type archive rewrite url
- How to rewrite the beginning and end of the permalink structure in a custom post type?
- Different post title, keywords and description
- How do I update_post_meta() or add_post_meta() with an AJAX call
- ACF Relationship Posts how to show additional content
- Change Post Meta via AJAX from the posts list table
- Catch and display error on save_post action
- How to create Custom image post?
- Weird issue where form field loses focus to previous form field even with JS disabled
- posts_per_page in custom WP_Query does not override “Reading” settings?
- How to store the third party script with HTML code in the wordpress custom input field?
- Show in an entry a Custom Post Type associated to a post
- Display Parent-Child Posts in specific order by comparing IDs in array
- How to display custom field in product description?
- Show code dependant on CPT & category
- How to make post title to appear after an image?
- Adding featured image to a new post using front-end form?
- Pagination on custom post type without plugin
- SEARCH QUERIES – REVERSE OUTPUT
- How can I check the rewrite slug of current post type listing page
- Static Front Page not working for custom theme
- post_type incorrect for custom post type
- How to configure the output of breadcrumbled CPT UI
- Live search by custom tag
- how to create custom taxonomy drop downs for parents and child
- Correct way to register custom post type from external php file?
- How to redirect from wp-admin/edit.php to a frontend page for specific custom post type?
- How to get the posts that my following users are liked?
- How to insert post 6 times after user register like ask.fm
- Only show categories that have posts within custom post type
- Not Able to List CPT Based on Taxonomy Term
- Duplicate Custom Post Type
- Filter Term By Parent Term – Custom Post Type
- Storing data in a multidimensional array from dynamically generated foreach loop
- Insert custom post type via XML-RPC?
- CPT or Custom Table for Repository of Serial Numbers
- How to Fix Custom WordPress Loop with Pagination on Single Post View?
- Best way to group posts based on custom post type terms
- erase post excerpt limitation [×]
- Using $seed on a custom post type for randomly displayed posts
- Can’t open Custom Post Types Link in navigation
- Remove custom taxonomy ‘post-type’ from post URL
- Problem with a query in custom posts
- Custom post-type’s pagination not working in category.php
- Using custom post types within a section of a template
- Pulling in a particular post into a single page based on the post id passed into the code
- 404 Error On Custom Taxonomy Pages 2, 3, etc
- Add post id to url instead of WordPress default -2 suffix
- How to consume external API from WordPress post editor and display the response data in the custom field?