Remove date time stamp from all posts

Posted in: Newspaper
Post count: 96

How can I remove date time stamp from entire theme? I don’t want Google to show date in its search result.

I tried following code in functions.php:

/* Start of Remove Date TimeStamp from blog posts */
function remove_post_dates() {
add_filter(‘the_time’, ‘__return_false’);
add_filter(‘get_the_time’, ‘__return_false’);
add_filter(‘the_modified_time’, ‘__return_false’);
add_filter(‘get_the_modified_time’, ‘__return_false’);
add_filter(‘the_date’, ‘__return_false’);
add_filter(‘get_the_date’, ‘__return_false’);
add_filter(‘the_modified_date’, ‘__return_false’);
add_filter(‘get_the_modified_date’, ‘__return_false’);
add_filter(‘get_comment_date’, ‘__return_false’);
add_filter(‘get_comment_time’, ‘__return_false’);
}
add_action(‘loop_start’, ‘remove_post_dates’);
/* End of Remove Date TimeStamp from blog posts */

However, it resulted in weird Jan 1, 1970 date in Google search snippet as shown in below screenshot:

I want to remove date time stamp as shown below screenshot:

http://www.wpsquare.com/wp-content/uploads/2012/07/remove-date-timestamp-google-search-results.png

Please help.

Post count: 341

Google may be taking it from your feed or sitemap or comments probably :/

Post count: 341

You’re using WP SEO plugin. In titles and meta settings, uncheck the box that says “dates in snippet previews” and you’ll be good to go.

Post count: 388

Wow… Google thinks your site predates the Internet…

Post count: 9544

Likely you would go into the loop file for the template you’re using;

e.g., loop-single1.php

comment out or remove this

<?php echo $td_mod_single->get_date(false);?>

Not sure if that is what you want …

Post count: 6600
Post count: 96

Thanks Lucian. It was really a big help. Thanks again.. 🙂

Viewing 7 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic.