Change has_archive to 'true'
-
I’m using the Genesis Framework which adds breadcrumbs to all my pages, including my single CPT for FAQs – it all works great except that the parent page to the single FAQ page does not get linked in the breadcrumb trail UNLESS the “has_archive” parameter is set to ‘true’ when you register this CPT during plugin installation.
SO the breadcrumb looked like this:
Home >> FAQ >> My cool single FAQWhen I needed it to look like this:
Home >> FAQ >> My cool single FAQ
I hacked the plugin to change that parameter to true so this would work correctly, but I’m requesting that you consider either making it an option, or just set it to “true” on future versions.
Unless I’m missing something, I can’t see a reason to set it to ‘false’ (?).
It would definitely bear noting that if it is set to true, the user MUST have a Page setup on which ALL FAQs are displayed (which they likely would anyway, otherwise why have FAQs, right?)…..if there is not a Page setup to display all FAQs, then that archive link would generate a 404 error.
Thanks!!
Changing that parameter to true makes
- The topic ‘Change has_archive to 'true'’ is closed to new replies.