wordpress date formatting

Is there any way to individually style each part of the date that wordpress puts in its post loop? In other words, when I use the php code:

<?php the_time('M j, Y') ?>

it comes out as “Feb 12, 2010”.

Read More

Is there a way I can style each word of the date differently? Like have the font-size for the word “Feb” be small and the font-size for the word “12” be really big.

I’d really appreciate it if someone could show how this is done.

By the way, the reason I am asking this is because I saw it done on a wordpress theme screenshot. I can’t find the actual wordpress theme, just the screenshot. Here’s the link to the image:

WordPress Theme Preview

Related posts

Leave a Reply

1 comment

  1. You can do that like this:

    <?php
      echo '<span style="font-size: 12">';
      the_time('M');
      echo '</span>';
      echo '<span style="font-size: 8">';
      the_time('j');
      echo '</span>';
      echo '<span style="font-size: 8">';
      the_time('Y');
      echo '</span>';
    ?>