Make category list custom post types – WordPress

The archive.php only list the post type “post” but you can change that with this simple snippet.

If you want to make your archive.php to list your own custom post types paste the following code into your functions.php
Then, the category and tag lists will also print the post types.

Add your own “your-custom-post-type” to the array list:

No comments yet, leave yours!

Leave a Reply

Add <code> Some Code </code> by using this tags.