wordpress categories template?

4 replies
does anyone know of a template that shows categories on the front page instead of posts?
#categories #template #wordpress
  • Profile picture of the author terrapurus
    Originally Posted by Wage Mills View Post

    does anyone know of a template that shows categories on the front page instead of posts?
    What you are looking for does not exist out of the box, but easy enough to build if you have some talent with working with the source files. Basically it means building your own home.php (which takes priority over the index.php file) that contains the code for the categories. It is a pain to get it laid out well though.

    As an alternative, grab a single column layout. Put the categories widget into the side bar (make sure it lays out categories and subcategories the way you want and you may have to tweak what you want). Now write a page and name it homepage and put some landing page content there. Give users a good funnel to go down that is easy to navigate. Make a second page called blog and leave it blank. Now go into your wp-admin panel, go down to settings and then (I think) reading and set your home page to be homepage and the second drop down to be blog.

    Now you have a custom home page with what ever you want on the home page and the categories set out in the sidebar.
    {{ DiscussionBoard.errors[2717898].message }}
    • Profile picture of the author Istvan Horvath
      Originally Posted by terrapurus View Post

      What you are looking for does not exist out of the box, but easy enough to build if you have some talent with working with the source files. Basically it means building your own home.php (which takes priority over the index.php file) that contains the code for the categories. It is a pain to get it laid out well though.
      No, it's not (a pain).

      Save your theme's index.php as home.php.
      Delete the Loop - and, eventually, keep the html tags (div, p, hx)
      Where you had the content related template tags, use a template tag that lists the categories. (yes, there are such template tags; find them in the Codex)
      Optionally, format the list by editing the html tags around it and/or by editing your css file.

      BTW, the title is misleading because there are category templates in WP but those are custom layout for different category archives.
      Signature

      {{ DiscussionBoard.errors[2718308].message }}
  • Profile picture of the author Louise M.
    not sure... but maybe you should have a look at some plugins that can do that rather than the theme itself. Or a code to add somewhere in your files... You can check out the Wordpress forum for that.
    {{ DiscussionBoard.errors[2717953].message }}
  • {{ DiscussionBoard.errors[2718081].message }}

Trending Topics