Custom post type archive page does not need “dumb” Page. In fact, there could be the culprit. You should try this:
- Remove
/* Template Name: Staff */
from archive-staff_member.php (not needed) - Remove “dumb” stuff Page (if created). There could be some permalink conflict.
- Go to Admin > Settings > Permalinks and re-save it (it will regenerate rewrite rules)
- Now just type URL … yoursite.com/staff_member/ (depends on
rewrite
setting in yourregister_post_type(...)
)
You should see only “staff member” posts. If yes, than wp_query is correct and is_post_type_archive()
will returns true. If it uses correct archive template too, you are done 🙂 If not (maybe 404 error?), then there is some misconfiguration.
And when you have yoursite.com/staff_member/
URL, you can add it to nav menu as “Custom link”. No “dumb” Page creation needed.
Related Posts:
- Page is defaulting to archive page and not designated template
- Create template for taxonomy results limited by Custom Post Type
- Custom Post Type Archives by Year & Month?
- Get custom post type slug for an archive page
- Adding a menu item for a Custom Post Archive
- Adding custom post type archives to a WordPress menu
- Meta_Query as a way how to setup CPT permalinks – is it a good thing?
- Proper way of making custom post type landing page or archive page
- How do I display two separate taxonomy archives for two post types that share a single taxonomy?
- Custom Post Type Archives by Date with Custom Permalink
- How to add meta box to backend menu page
- Change title in head on Archive page
- Custom Post Type Archives with 0 Posts Redirects as 404
- Custom Post Type Archive URL takes over page URL
- Better to use a post type archive, page template, or shortcode for generating a highly configurable CPT archive?
- paginate function in archive for custom-post-type
- where can I see my custom post type archive template?
- Custom post type archive sorted and grouped by date in post meta field
- Create Custom Post Type Archive Page with Sub Categories Navigation Sidebar
- How to create archive page for taxonomy terms within custom post type
- Custom Post Type .current-menu-item not applying on Custom Post Type Archive Page
- WordPress custom post type archive with description
- Custom-post-type-archive: posts sorted/filtered by year?
- How to list custom post types?
- Custom post type archive page pagination
- Add the current menu item CSS class to a custom page type archive in WordPress menu
- Editable content on a Custom Archive page
- Second Custom Post Type Archive
- How to show the archive / post type description on Single templates
- is_main_query() not working for WP REST API
- Custom template page with custom archives listing by user
- CPT Archive with core Category
- Set up Custom-Post-Type Author Archive
- Changing number of posts per page on CPT-archive.php, have tried 20-30 code chunks so far
- get the custom post type title/name
- URL of a custom post type’s post format archive?
- Custom post type archive page blank
- How to display custom post in archive section of the wordpress page?
- How can I get this request to use the Custom Post Type page template instead?
- Archive for a Taxonomy of a Custom Post type
- What’s the name of the custom post type yearly archive template?
- how to remove pages loading with the archive templates
- Return the name of the post type
- Use the custom post type archive for taxonomies?
- Custom Post Type setup
- Archive page for custom post type and custom taxonomy
- Archive Template being used instead of Category Template for Custom Post Type
- How to have multiple archive pages?
- Create a Custom Path to Archive
- Custom Post Type Date Based Archive URL rewrite [duplicate]
- How can I allow users to edit text that will be displayed on a custom post type archive page?
- Specifying a template for custom post type pages
- WordPress sitemap with Custom Post Types
- Is possible register two archive pages for single custom post type?
- Custom Post type page content (archive page)
- Group custom post type posts by month
- Creating an archive page or simple template to list all values of a custom field of specific post type listing
- Do not show child pages within a file page
- Tell wordpress to show a single page instead of an archive page
- Custom Post Type archive page listing a 404 or single post
- Turning archive templates to a page template maintaining the slug
- get_permalink() of page the enclosing page not posts
- Want to display my custom date archive to date.php but dont know how
- Custom post type with two templates
- Custom Post Type tag taxonomy “Page Not Found”
- Custom nav menu current item custom link problem
- Rewriting archive page slug to be different than custom post type slug
- Site loads very slow for archive custom post type page
- Stop Custom post type from being searched via URL
- How to display custom post types AND regular posts separately on a shared taxonomy archive?
- How to display the FAQ Archive page in my menu
- Custom post type category page not working
- paging is not working properly on news archives page [duplicate]
- How can I set up the URL for a category archive for a custom post type?
- CPT Archive with parent page
- Taxonomy Query of Custom Post Displays Archive Instead of Posts
- Pagination not working for archive
- how to pass args for archive.php query?
- How to have a dynamic slug and rendering the archive-{post_type}.php?
- Remove plugin’s custom post type archive page and single pages [closed]
- Custom Post Types using wrong template (index) instead of archive-{type}.php – previously worked as expected
- Can’t add custom post type archive page to menu
- WordPress CPT archive page display sticky post first and then display the rest of the posts in same Query
- How to make an archive page displaying posts in a date range
- Slug for standard post post_type
- How do I create an archive page for standard posts?
- Get post type from taxonomy or category page
- custom taxonomy archive by year
- Query with no terms uses index.php template instead of archive.php
- WordPress post_where & posts_join not working only for custom post type
- Custom templates for a specific category
- How to rewrite custom taxonomy term archive to use THE SAME SLUG/front as CPT
- How can I relate custom post types?
- Tag template not returning posts [closed]
- Custom post type posts wont show in wp_nav_menu()
- Custom Post Taxonomy Template Not Loading Properly
- Templating advice sub posts of a CTP
- Custom post type post_type_link gives “page not found” on any other custom post type
- Custom Post Type shows pagination (w/404) or posts_per_page query, but not both
- Have two (permalinks) urls for a same custom post type