Forums

Problem , dates only on first post of the day (3 posts)

  1. jiggybytes
    Member
    Posted 3 years ago #

    The main page only shows the date for the first post of the day, not for the following posts.

    This is my index.php. Also, I should say this is my first time working with WordPress.

    <?php
    get_header();
    ?>
    
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div class="post" id="post-<?php the_ID(); ?>">
    	 <h3 class="storytitle"><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h3>
    	<div class="meta"><?php the_category(',') ?> — <?php the_tags(__('Tags: '), ', ', ' — '); ?>Skrivet den <?php the_date() ?> <?php edit_post_link(__('Edit This')); ?></div>
    
    	<div class="storycontent">
    		<?php the_content(__('(more...)')); ?>
    	</div>
    
    	<div class="feedback">
    		<?php wp_link_pages(); ?>
    		<?php comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')); ?>
    	</div>
    
    </div>
    
    <?php comments_template(); // Get wp-comments.php template ?>
    
    <?php endwhile; else: ?>
    <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
    <?php endif; ?>
    
    <?php posts_nav_link(' — ', __('&laquo; Previous Page'), __('Next Page &raquo;')); ?>
    
    <?php get_footer(); ?>

    Any clues as to what is causing this?

    Thanks!
    Jimmy

  2. mojorob
    Member
    Posted 3 years ago #

    The Codex tells you this - search is your friend!

  3. jiggybytes
    Member
    Posted 3 years ago #

    Replaced <?php the_date() ?> with <?php the_time('j F, Y'); ?>

    Thanks Mojorob, that solved it.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags