Hi there. I’d like to add the time a post was first published in the top of the post. It currently shows the day month and year and has the following code:
<?php $time = get_the_time('M d Y'); list($mo, $da, $ye) = explode(" ", $time); ?> <div class="date" title="<?php the_time('d-m-Y'); ?>"> <p> <span class="month"><?php echo($mo); ?></span> <span class="day"><?php echo($da); ?></span> <span class="year"><?php echo($ye); ?></span> </p> </div>
How would I modify this to add a line for time above the date. Thanks very much.
- The topic ‘Adding the Post Time to my Template’ is closed to new replies.