Make a Custom template for a specific category in wordpress

I am having issue with a custom category template. I want to create a new template for my specific category “VIDEOS” so that all posts under this category show in new style. Basically, i want to show posts with videos in a new way as 3 posts in one row with featured images and a featured slider on top of that page showing 4 new posts of that category ?

But i am confused… Can i do this in wordpress ? Because my home page also has a featured slider. Can i create a new slider for that page template but one thing is sure. I need to work with only one category for that custom template i.e. videos………

Related posts

Leave a Reply

3 comments

  1. Just create category-[id].php & you will be ready to use that. WordPress will automatically load that file for that ID of category.

    You can also do same task via slug like category-files.php etc as well

  2. Yes, certainly possible with WordPress.

    Find the slug or the category id. Your slug for the category may be videos. So create a custom template named category-videos.php. This template will be used for the category archive VIDEOS.

    If you know the category id, you can create template named category-<category_id>.php.

  3. For other people landing on this page and wondering what to do when they go to their theme’s folder and don’t find a file called “category.php”, what you need is to find the next file in the hierarchy, copy it, and rename it category-[slug or id].php (this should be archive.php, followed by index.php).

    For a listing of the category hierarchy, see the official documentation: http://codex.wordpress.org/Category_Templates