Home › Forums › Bug Reports › ‘Page Attributes’ selection for Custom Post Types not working
I’ve requested a support ticket on this topic but thought I ought to share it here too in case it is affecting others.
When selecting ‘Page Attributes’ under ‘Supports’ for a new custom post type, there is no option under the ‘Page Attributes’ section on the editing page to select a new custom page template (or switch between the theme templates). Only the page ‘Order’ is shown, with the option of changing that.
This isn’t fixed by making the custom post type hierarchical. I’ve tried this on a completely fresh WordPress install, with several default WordPress themes and can’t find a theme / plugin conflict going on.
It’s a shame, as it’s otherwise great to be able to work with custom post types and fields all from within the same plugin. Anybody having the same issue?
Yes, I’m having this issue too. Any thought on how it can be resolved?
Hi there – the reply I received from ACF is below. I had actually got it to work by amending the template file header, but assumed that the ACF plugin would be able to edit that itself automatically:
–
Hi there,
Thanks for reaching out to us and sorry for the massive delay on this one.
In order to render the Template dropdown, you need to add the CPT key/slug to the custom template file header as described here: https://developer.wordpress.org/themes/template-files-section/page-template-files/#creating-page-templates-for-specific-post-types.
Template Post Type: custom post key/slug here
That way the Template dropdown will appear on the Attributes section.
Please try this and let me know how it goes.
Thanks,
Said
–
Hope that helps.
You must be logged in to reply to this topic.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.