If you have troubles since the update to WordPress 4.5 please read this post before opening a new thread.
is there any way to add the year to the date badge that is shown beside each post on wide browser windows? It would be great if the second line could simply show “NOV 12” instead of just “NOV”. This would give readers a bit more orientation when searching and finding older articles.
Thanks for any hints,
Yes, open up sentenceincludesformat-standard.php and replace following line:
<span class='date-month'><?php the_time('M') ?></span>
<span class='date-month'><?php the_time('M Y') ?></span>
at the time when you were posting the answer, I had already fixed it. (Sometimes you just have to re-think ater some minutes.) However, I also had to change all other format-*.php files to get it really working. I also used
<span class='date-month'><?php the_time('M y') ?></span> (with a small “y”) to get the year in only two digits. At the same time, I switched
<span class='date-day'><?php the_time('d') ?></span> to
<span class='date-day'><?php the_time('j') ?></span> to get rid of the leading zero.
See the result (work in progress) at maennig.de, if you like.
The topic ‘Add Year to Date Beside Post’ is closed to new replies.