Skip to content

Instantly share code, notes, and snippets.

@thecodepoetry
Created January 8, 2015 08:44
Show Gist options
  • Save thecodepoetry/693302bee18f3c4e4196 to your computer and use it in GitHub Desktop.
Save thecodepoetry/693302bee18f3c4e4196 to your computer and use it in GitHub Desktop.
Remove link from date The7.2
function presscore_get_post_data( $html = '' ) {
$href = 'javascript: void(0);';
if ( 'post' == get_post_type() ) {
// remove link if in date archive
if ( !(is_day() && is_month() && is_year()) ) {
$href = presscore_get_post_day_link();
}
}
$html .= sprintf(
'<time class="entry-date" datetime="%s">%s</time>',
esc_attr( get_the_date( 'c' ) ), // datetime
esc_html( get_the_date() ) // date
);
return $html;
}
@thecodepoetry
Copy link
Author

Add this in functuions.php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment