Forums

Page Display of blog posts (5 posts)

  1. ae6dx
    Member
    Posted 2 years ago #

    On my monthkly archive and category pages I'd like to display only the entry title and date rather than the whole entry. How do I do this?

  2. kz
    Member
    Posted 2 years ago #

    Create archive.php and edit it like this:

    <?php
    if(have_posts()) :
      while(have_posts()) :
        the_post();
        ?>
        <h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
        <div class="date"><?php the_date(); ?></div>
        <?php
      endwhile;
    endif;
    ?>
  3. ae6dx
    Member
    Posted 2 years ago #

    What about for categories?

  4. kz
    Member
    Posted 2 years ago #

    Dont worry. It works fine with both monthly archive and category archive.

  5. henkholland
    Member
    Posted 2 years ago #

    Unless your theme has a category.php but then do the same there!

    http://codex.wordpress.org/Template_Hierarchy to learn what template is active for which view.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.