Creating single post and archive templates
-
Hi Michael,
I am currently building a website and its the first time I am dealing with CPT’s so your input is greatly appreciated here.
Basically I created a new custom post type called “hotels”. Now I would like to create a single post type template that will be specifically used with “hotels”. I know that I can copy the code from single.php as a base and create my custom single-hotels.php template.
My theme has some other CPT’s registered with the theme. Those are news, portfolio, team, etc. My question is, where exactly do I have to place my single-hotels.php file.
FYI- I am using a child theme.
Same thing goes to archives-hotels.php, where exactly do I need to put this file?
Thank you in advance for any assistance.
Regards,
X
- The topic ‘Creating single post and archive templates’ is closed to new replies.