WordPress.org

Ready to get started?Download WordPress

Forums

Reverse Chronological Order of Comments (5 posts)

  1. Brett-Morrison
    Member
    Posted 5 years ago #

    I too would like to revers the order of my comments but the other solutions haven't worked. Below is the code of my index.php can someone correct the code to get the order descending.

    <?php get_header(); ?>
    <div id="bd" class="yui-navset">

    <div id="yui-main">
    <div class="yui-b" >
    <div class="yui-g">

    <?php if (have_posts()) : ?>

    <?php while (have_posts()) : the_post(); ?>
    <!-- item -->
    <div class="item entry" id="post-<?php the_ID(); ?>">
    <div class="itemhead">
    <h3>" rel="bookmark"><?php the_title(); ?></h3>
    <div class="chronodata"><?php the_time('F jS, Y') ?> <!-- by <?php the_author() ?> --></div>

    </div>
    <div class="storycontent">
    <?php the_content('Read more »'); ?>
    </div>
    <small class="metadata">
    <span class="category">Filed under: <?php the_category(', ') ?> <? if(!is_single()) echo "|"; ?> <?php edit_post_link('Edit', '', ' | '); ?> <?php comments_popup_link('Comment (0)', ' Comment (1)', 'Comments (%)'); ?></span>
    <?php if ( function_exists('wp_tag_cloud') ) : ?>
    <?php the_tags('<span class="tags">Article tags: ', ', ' , '</span>'); ?>
    <?php endif; ?>
    </small>
    </div>
    <!-- end item -->

    <?php comments_template(); // Get wp-comments.php template ?>

    <?php endwhile; ?>

    <div class="navigation">
    <div class="alignleft"><?php next_posts_link('« Previous Entries') ?></div>
    <div class="alignright"><?php previous_posts_link('Next Entries »') ?></div>
    <p> </p>
    </div>

    <?php else : ?>

    <h2 class="center">Not Found</h2>
    <p class="center">Sorry, but you are looking for something that isn't here.</p>

    <?php endif; ?>
    <!-- end content -->
    <!-- 2nd sidebar -->

    <!-- end 2nd sidebar -->
    </div>
    </div>
    </div>
    <div class="yui-b" id="secondary">

    <?php get_sidebar(); ?>

    </div>
    </div>
    <?php get_footer(); ?>

  2. esmi
    Forum Moderator
    Posted 5 years ago #

    Try going to Admin/Settings/Discussion and using the dropdown to reverse your comment order from oldest to newest (or vice versa).

  3. Ryan S
    Member
    Posted 5 years ago #

    Correct. Look at Other comment settings.

    Comments should be displayed with the [DROPDOWN] comments at the top of each page. Select your option.

  4. Brett-Morrison
    Member
    Posted 5 years ago #

    Thank You

  5. Brett-Morrison
    Member
    Posted 5 years ago #

    I have tried all of the settings and they don't seem to be affecting the lineup. Could this be because I updated to the newest version. Nothing changes when I use these.

Topic Closed

This topic has been closed to new replies.

About this Topic