Forums

get_month() Function and Clean Archives Reloaded (1 post)

  1. gkp99
    Member
    Posted 1 year ago #

    Hi,

    I'm trying to customise Viper007Bond's Clean Archives Reloaded plugin. When listing each post title in a particular month, I am trying to add a <span> class after the post title with that post's date in the format: "day month" (i.e. 7 June). I'm almost there but it currently outputs "day month year" (i.e. 7 June 2010). Below is the line where this is happening:

    $html .= '<span class="post-date">' . mysql2date( 'j', $post->post_date ) .' ' . sprintf( __('%1$s %2$d'), $wp_locale->get_month($month), $year) . '</span>'

    I basically can't figure out how to change the function get_month() to not return the year but my PHP knowledge is laughable at best. I'd appreciate any help you could offer.

    Thanks

Topic Closed

This topic has been closed to new replies.

About this Topic