From what I recall, if a page is a child of another page, the pagename value is the full parent / child path. In your examples it would be pagename=questions/ask
and pagename=questions/ed
, though you say the first rule works, which is puzzling.
also, side note – there’s a locate_template
function that will correctly handle parent / child themes.
Related Posts:
- Post/Page Preview Template
- Custom permalink structure only for default posts
- Is it possible to have two different previews of a post (ie. two templates for one post)?
- Display page content AFTER a loop of posts
- Using custom post template
- Custom Post Type – Category Rewrite – Remove Rewrite from Sitemap
- Duplicate Custom Post Type and Taxonomy Slug
- custom post template file not shown, instead all the time 404.php
- How do I Redirect a WordPress Page?
- Tell WP to use a specific template file in posts
- Create a custom posts page
- Custom Post Type, post-formats associated to custom post type > 404 archives
- How to allow WordPress to recognize a custom URL segment after a product URL and use a custom template?
- Redirect to custom post if custom archive page has just one result?
- how to redirect page after delete post inside a post page?
- Custom post type template not called
- single- and archive- templates not being applied to custom post types, not even after flushing permalinks
- issue in wordpress auto delete post and redirect to another 1
- Adding The Post Template Dropdown to WP-Admin
- custom post type single page template not working
- Post pages are redirecting to the 404 page in wordpress
- Custom Post Types, slug, archive and SEO plugins
- Search Custom Post Type Pages and Custom Fields in 2 Dropdowns?
- How to get Images included in Post
- How to disable drafts?
- how to enable different number of revisions for different blogs when using WPMU?
- Custom Post Type Pagination Doesn’t Work in WordPress 3.4
- Unattaching images from a post
- Allow role to delete posts but block him the wp-admin
- How only display all post related to category
- Using Custom Posts with Metaboxes and Drop-downs
- How to show featured image in custom post type dashboard post page
- Posts vs. Pages
- Dynamic carousel on individual posts
- How to support custom templates on a custom post type?
- Filter Custom Post Type by Category with Ajax
- Plain permalinks not working!
- How to add pagination in between post and comments?
- Changing Permalinks for Default Post type to reflect navigation
- Print all the tags from a custom post type Please
- Display multiple custom taxonomy values on single custom post types page?
- Show posts by a custom post author
- Custom loop pagination links not working
- wp-cli post create & media import issues
- Unable to restore from backup – how to obtain old blog posts?
- Getting value from get_post_custom
- Set Default Category to Username
- show custom post type category dropdown sorting result on same page
- Custom Post Type Rewrite To Include Parent Page(s)
- How To Load an HTML File As A WordPress Page (With No 301/No Redirect)
- How do I insert a post with custom post type and relate it to a custom taxonomy?
- Dynamically switch template on click
- Custom taxonomy archive page problem
- How to make different custom post layouts?
- Two Custom Post Types with Identical Articles Competing for the same Slug
- Custom Post Type archive
- Is it possible to give the user the chance to select between two single template files to use in a post?
- How to identify and hide/remove an element from a WordPress page [closed]
- if in category but only with post meta
- How to add convenient buttons for new custom post statuses
- Auto delete posts based on content text
- Custom home page with full post for first one only
- Display value of custom field at the beginning of a post
- Can WordPress handle following functionalities?
- How do I disable the “by author” hyperlink on posts?
- Changing permalink of WordPress
- Hook save_post_cpt not triggered when custom fields are modified
- Redirect old Posts URL to new URL
- Pagination Not Working With Custom Post Type Category
- WordPress Pods Custom Post Type – separate Media Upload folder for each custom Post Types
- Put page on Archived statut after end of publication date
- post and page and custom post type
- My posts page is missing the page title
- Show custom post category for single post
- How can change header text in post careate/edit form
- Add Categories To Custom Post
- Is it possible to query a category with specified posts?
- How do I set content in my pages so that it remains permanent while blog posts are added below?
- Permalink base only for posts
- Difference between modified post and new post
- Creating widget – ask for selecting a post in the admin panel
- wp query custom orderby not custom field
- Custom Single Post Type not referring to single-post-type.php File
- Redirect Every Instance of The Author Template Pages to Custom Author Pages
- My blog “page” used to show a list of posts, but now it’s just showing the page content?
- Custom template for different post types
- How to modify specific parts of a post content in WordPress
- Include post on external custom site
- Use a custom post URL that is outside the blog root directory
- Posts page template: How can I edit the markup for this?
- “Current” class on a singular page menu item with custom post types?
- Which hooks are essential for post templates?
- Redirect posts to sub domain except pages
- How can I allow users (subscribers) to download selected posts into a single PDF? (RESOLVED)
- Choose options via url
- Custom Post Type Pagination 404 Error (if paged>=2) [duplicate]
- Display ONLY Latest Post From Several Categories
- Display post structure in function
- Is there a block to print post link standalone in a block theme?
- Notify/check if the content of a custom gutenberg block has changed on save_post