Adds .updated class to .entry-date when needed

This commit is contained in:
Slobodan Manic 2014-06-15 13:20:06 +02:00
parent 31ac4d2b2d
commit 00570514d4
2 changed files with 4 additions and 2 deletions

View File

@ -66,9 +66,11 @@ if ( ! function_exists( '_s_posted_on' ) ) :
* Prints HTML with meta information for the current post-date/time and author.
*/
function _s_posted_on() {
$time_string = '<time class="entry-date published" datetime="%1$s">%2$s</time>';
if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) {
$time_string = '<time class="entry-date published" datetime="%1$s">%2$s</time>';
$time_string .= '<time class="updated" datetime="%3$s">%4$s</time>';
} else {
$time_string = '<time class="entry-date published updated" datetime="%1$s">%2$s</time>';
}
$time_string = sprintf( $time_string,

View File

@ -555,7 +555,7 @@ a:active {
margin: 0 0 1.5em;
}
.byline,
.updated {
.updated:not(.published) {
display: none;
}
.single .byline,