I want to make a TV Show database in Wordpress that has this URL format:

  • /tvshows/ would list all series
  • /tvshows/friends/ would list all the seasons available for Friends TV Show
  • /tvshows/friends/01/ would list all episodes of Friends from season 1
  • /tvshows/friends/01/12/ would show information on the 12th episode of the first season

And here are the different methods I've thought about:

1) The first idea that came to my mind is to create Pages and nest them accordingly. Then create 3 different page templates (TVShow.php, Season.php and Episode.php) and style each page accordingly. The main drawback is that once there are 200 series with 4 seasons and 25 episodes each (total of 20,000 pages) it can be a complete mess to update and find everything. (Another drawback is the RSS feed although this can be solved through plugins)

TV SHows - Page-based

2) Some colleagues suggest me to use Custom Posts but these do not have a hierarchical structure and although I could then use mod_rewrite to make the URLs nice I guess it would be even more hassle than using Pages. (There's this plugin that manages custom posts through a UI although I cannot figure out how to create a hierarchical organization)

3) The last idea is to have them as normal Posts and then Categorize them by Serie name, season and episode hence avoiding all the custom post hassle and using simple Wordpress API functions to list and display everything.

Those are the best/possible ways I can think of, the Page-based option may be the most suitable although scalable in a painful way once there are +500 pages.

Any ideas, suggestions on how to organize this?

Thanks in advance! :)


2 Answers 2


First, you shouldn't do this with the built in post types of post or page. Use a custom post type.

Example: movies and series, where movies is non-hierarchical, but series is.

Use register_post_type() and set hierarchical to true (default: false). Take a look at the rewrite argument > with_front to prepend /series/.

Then add some templates:

  • series-list.php,
  • series-detail.php,
  • series-season.php,
  • series-episode.php...

Justin Tadlock created a movie database using custom taxonomies that achieves something similar and he describes it in a tutorial here

  • Thank you Carson, I'll need a hierarchical structure which is not used in the tutorial although it gives a great overview and I may use it in a future if we ever decide to add movies too Jun 17, 2011 at 10:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.