Support » Fixing WordPress » Post Subpages By Date

Viewing 5 replies - 1 through 5 (of 5 total)
  • With the help of the Template Hierarchy article, determine what Template is displaying “1. domestic violence”, then paste the content of that template in a pastebin and report the link back here.

    Hi Micheal H. Thanks for your reply. I named my pages with the numbers purposely so maybe you can ignore that part of it.

    Here is my Template:

    Template Name: Discussions

    <?php get_header(); ?>

    <div id=”side-left”>
    <div id=”content”>

    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div class=”kutu”>
    <div class=”ust”><span></span></div>

    <div class=”post” id=”post-<?php the_ID(); ?>”>
    <h2 class=”pagetitle”><?php the_title(); ?></h2>
    This section is an open forum for viewers to discuss & debate random topics per week. I will be posting “The Topic Of The Week” as it will allow us to converse about highlights of the media, politics, celebrity gossip, life & relationships, and parenting. Topics are posted in a numerical order (the highest number being the most recent topic) For those that are subscribed, you will receive an email notification when the new topic is posted! So if you’re interested in being involved, please subscribe to my mailing list. Thank you.

    <div class=”entrytext”>
    <?php $children = get_pages(‘child_of=’.$post->ID.’&show_date=modified
    &date_format=$date_format’);if ($children) : ?>

    <?php endif; ?>

    <?php endwhile; endif; ?>
    <?php edit_post_link(‘Edit this entry.’, ‘<p style=”margin:10px;”>’, ‘</p>’); ?>
    <br class=”clear” />
    <div class=”alt”><span></span></div></div>

    <?php get_sidebar(); ?>

    <?php get_footer(); ?>

    Not sure what this is doing for you:

    <?php echo get_the_title($post->DATE); ?>

    so try this instead:

    <small><?php the_time('m.d.y') ?></small>

    That worked Michael to show the date, but it just replaced the Subpage title with the date.

    * 02.28.09 (5 comments)
    * 03.08.09 (4 comments)

    That’s what’s there now.

    Ok I fixed it. I implemented the other code back into the post:

    <?php echo get_the_title($post->DATE); ?> <small><?php the_time(‘m/d/y’) ?></small>

    Thanks for the help Michael!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Post Subpages By Date’ is closed to new replies.