dimanche 1 mars 2015

Attach a custom post type archive to a static page


So lets say you have a static home page and your posts page is a page called "Blog" or something along those lines. Using <?php post_type_archive_title(); ?> in the header.php will then allow the heading of the "Blog" page to show correctly as "Blog" instead of the first post name, and also displays single static pages correctly. How do I go about replicating that for custom post types? I'm trying to avoid using loops in the header.





Aucun commentaire:

Enregistrer un commentaire