- This topic has 30 replies, 4 voices, and was last updated 1 year, 6 months ago by Paul.
December 31, 2019 at 6:02 am #1118250Paul
I recently created (Leo is familiar) a new custom post type called “Projects” – I’d like some help creating a custom hook for this CPT to display just like the single post. In addition I would like to have a page set up to display all the projects just like the blog page does for posts. Thanks!December 31, 2019 at 1:54 pm #1118656LeoStaffCustomer Support
CPT should show up in the display rules by default. Is it not showing for you?
As for displaying posts for CPT, you could consider using this plugin:
https://en-ca.wordpress.org/plugins/wp-show-posts/December 31, 2019 at 7:47 pm #1118736Paul
Sorry if my question was not clear.
The CPT shows up – my question is for formatting the pages.
I would like this page (CPT) https://www.trademarkinteriors.com/projects/kitchen-remodel-wyckoff-nj-3/ to look like this page format https://www.trademarkinteriors.com/wet-bar-vs-dry-bar-full-review-and-comparison-of-home-bars/
Thanks.December 31, 2019 at 8:40 pm #1118748PaulDecember 31, 2019 at 8:42 pm #1118749Paul
I should clarify for the project page – I’m happy to use the WP show posts, just looking for a custom hero header.January 1, 2020 at 10:38 am #1119201LeoStaffCustomer SupportJanuary 1, 2020 at 11:05 am #1119227Paul
It worked for the single CPT, not for the project page https://www.trademarkinteriors.com/projects/January 1, 2020 at 5:23 pm #1119370LeoStaffCustomer SupportJanuary 1, 2020 at 5:55 pm #1119388Paul
Adding the CPT to the the display parameters added the header properly.
I tried the same for this page https://www.trademarkinteriors.com/projects/ but the header does not appear. Looks like I will need help with a hook for this page.January 1, 2020 at 6:09 pm #1119391Paul
At this point I just need a hook to display a hero image similar to the blog page except it will be a static image (blog page changes with latest post). Thanks!January 1, 2020 at 8:46 pm #1119447TomLead DeveloperLead Developer
In that case, you may want to create a new Header Element just for the projects page. That way you can explicitly set a hero image for it in the settings 🙂January 2, 2020 at 5:03 am #1119698Paul
Initially I tried that and it did not work so I believe I became confuse thinking I needed a hook element. I do see that there is a custom header element for merged header that applies to all pages, would I need to exclude the project page in that element in order for the new header element to work? Thanks.January 2, 2020 at 7:41 am #1119967DavidStaffCustomer SupportJanuary 2, 2020 at 7:47 am #1119973Paul
Happy New Year to everyone!!
Good to know – I tried that and it still does not appear so I modified the hook for the blog to the following which worked! Just let me know why the header element does not work??<h1>
</h1>January 2, 2020 at 8:45 am #1120025
- You must be logged in to reply to this topic.