WordPress.org

Ready to get started?Download WordPress

Forums

Display a list of days in a monthly archive? (2 posts)

  1. bradyjfrey
    Member
    Posted 8 years ago #

    I would not like to show all the posts of a specific month, but I would like to show a list of days with posts on a specific month via archive.php -- it would look:
    Archive for Archive for March, 2006

    • March 1st
    • March 2nd
    • March 3rd

    etc... all of the days for an archived month. Those links would take you to the archive page that has all the specific posts for that day.

    Any clues on how to code this outside of the loop? I've tried:

    <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
    <h2 class="entrydate">Archive for <?php the_time('F, Y'); ?></h2>
    <?php get_month_link('year', 'month'); ?>

    and:

    <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
    <h2 class="entrydate">Archive for <?php the_time('F, Y'); ?></h2>

      <?php wp_get_archives('monthnum=$current_month&type=daily'); ?>

    and:

    <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
    <h2 class="entrydate">Archive for <?php the_time('F, Y'); ?></h2>
    <?php $current_month = date('m'); ?>
    <?php $current_year = date('Y'); ?>

    <?php query_posts("year=$current_year&monthnum=$current_month&order=ASC"); ?>

    None have been successful -- I'm sure this is easy to do and I am missing something, thank you!!

  2. bradyjfrey
    Member
    Posted 8 years ago #

    No ideas, anyone?

    All I want is if you click on the monthly archive, it doesn't display every post for that month, but every day of posts, like:

    Archive for Archive for March, 2006
    March 1st
    March 2nd
    March 3rd

    Looks like I'll need to make me a plugin...

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.