1
votes

the WordPress framework allows to build different archive templates for each of your custom post type by e.g:

archive-event.php
taxonomy-event_category.php

is it possible to create author and date archive for custom post type by doing the following:

author-event.php
date-event.php

if this is not possible, can anyone advise how i can go about achieving this?

1

1 Answers

0
votes

I think these links will help answer your question and get you started: http://codex.wordpress.org/Template_Hierarchy http://codex.wordpress.org/Category_Templates

The gist of it is that you can in fact make an author-event.php however date-event.php does not get checked because the template hierarchy dictates that it uses date.php, archive.php, or index.php.

One solution is to use conditional tags such as is_author() or is_date(). If you do, keep in mind that you'll have to have a common archive.php and decide which template you really want to use by using conditional tags.