Trying To Show SubCategories In Wordpress

Discussion in 'PHP' started by Ssj2GohanTeen, Dec 1, 2009.

  1. #1
    Hi

    I have 2 main categories called Movies and Tv-Shows.
    Both have subcategories for every movie or tv show. I really want to list
    these movies and series but only way i can think of is a category page.
    Unfortunately a category page shows all posts in the subcategories instead
    of showing all subcategories. Anyone knows how i can code it so that the
    subcategories from movies and tv-shows are both nicely listed at a page
    called tv-shows and movies or at the archive /category/tv-shows?

    Regards,
    Max
     
    Ssj2GohanTeen, Dec 1, 2009 IP
  2. shallowink

    shallowink Well-Known Member

    Messages:
    1,218
    Likes Received:
    64
    Best Answers:
    2
    Trophy Points:
    150
    #2
    create a category template file for each category you want to list (if you want to use all or a lot, just create category.php) like category-movies.php. see here for details :

    http://codex.wordpress.org/Category_Templates


    and then use this code :
    replace the 8 with the correct category id for the cat. and the code was taken from here :
    http://codex.wordpress.org/Template_Tags/wp_list_categories
     
    shallowink, Dec 1, 2009 IP
  3. Ssj2GohanTeen

    Ssj2GohanTeen Member

    Messages:
    102
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    28
    #3
    Alright ill try it out right away :)

    Edit, thnx for the help, its solved now
     
    Last edited: Dec 1, 2009
    Ssj2GohanTeen, Dec 1, 2009 IP