template parts calling dynamic page
-
Hi Guys,
So take
<?php get_template_part( 'loop-templates/content', 'page' ); ?>
…how do I adjust this so that when I visit a page with a slug say about-us that the code pull the template file loop-templates/content-about-us.php if it exists if not default to content-page.
I’d like to pull a template part based of a dynamic page or category using a slug system.
New to WP so trying to figure the logic.
Thanks
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘template parts calling dynamic page’ is closed to new replies.