This is a nifty little thing to know, and one of those annoying little feckers that will torment you if you don’t know how to change it
Walsho recently asked for help on this and said that he’d come to me for help – no worries Walsho, smemon to the rescue.
In admin panel, go to Presentation > Theme Editor (anytime you change your theme, you’ll have to do this).
Now click on ‘Main Index Template’ or ‘index page’ or something with the word ‘index’ in it, every theme is different.
Scroll down ’till you see the word time somewhere – STOP. (Here’s what the start of my file looks like, the red bit is the bit you’ll need to change).
<?php get_header(); ?>
<?php if(have_posts()): ?>
<?php while(have_posts()) : the_post(); ?>
<div class=”post” id=”post-<?php the_ID(); ?>”>
<h2><a href=”<?php the_permalink(); ?>” title=”Permanent link to <?php the_title(); ?>”><?php the_title(); ?></a></h2>
<?php the_time(“g:i a”); ?>, <?php the_time(“jS”); ?> <?php the_time(“M”); ?> <?php the_time(“Y”); ?>, posted in <small class=”categories”><?php the_category(‘, ‘); ?></small><?php edit_post_link(‘Edit Post’, ‘<span class=”editlink”>’, ‘</span>’); ?>
<span class=”comments”><?php comments_popup_link(‘0 comments’, ‘1 comment’, ‘% comments’, ‘commentslink’); ?></span>
<?php the_content(‘Read the rest of this entry Â»’) ?>
<?php trackback_rdf(); ?>
Simply translated, that bit in red = “1pm, 1st Jan 2008″ or something like that.
Say you want your time/date to display as “2008, Jan 1st, 1300″, you’d change that bit in red to;
<?php the_time(“Y”); ?>, <?php the_time(“M”); ?> <?php the_time(“jS”); ?>, <?php the_time(“g:i”); ?>
So basically you’re only editing the values in ” ” inverted commas.
Note: you may also have to change this in ‘page template’ or anywhere else the time function is displayed, as wordpress can be contrary if times don’t match up.
For a full list of values to put in those ” ” inverted commas, see the wordpress codex here.
WTF i hear you say Since when did smemon become a codemonkey! Well, i *did* say i was reading up ebooks and trying to code and design wordpress themes… so i guess i’m learning something