• Resolved LeonWeb

    (@leonweb)


    Hello,
    Could you help me, please?

    I see a not very good snippet, when i type some of my article’s name in Google’s Search.
    Because I see a date + TIME + short text of my article, in the snippet in Google’s Search Results.
    How can I remove the “time information“, from snippet in Google’s Search Results?
    I think it is in the post-meta.php file, but I’m not sure…

    <span class=”entry-date”><i class=”fa fa-clock-o”></i><abbr class=”published” title=”<?php echo esc_attr( get_the_date( ‘c’ ) ); ?>”><?php echo the_time( get_option( ‘date_format’ ) ); ?></abbr></span>
    <span class=”meta-no-display”>” rel=”bookmark”><?php echo the_title_attribute(); ?></span><?php echo $modtime; ?>

    Hope you understand my bad english…

Viewing 6 replies - 1 through 6 (of 6 total)
  • Theme Author Richie KS

    (@rkcorp)

    its the microdata date for search engine. the search query in google are not dependable, sometime it show the date stamp sometime not, depend on user query.

    search for wp plugin that remove datestamp for google index listing. forgot the plugin name already.

    Thread Starter LeonWeb

    (@leonweb)

    Thank you!
    I’ll try to find it.

    But there is still a question…
    How I can edit the post-meta.php for this:
    I need to disable pop-up text (with time information) when mouse hovers under title on post-entry article..
    I’m trying to find a solution somewhere here:

    <?php
    $getmodtime = get_the_modified_time(); if( !$getmodtime ) {
    $modtime = ‘<span class=”date updated meta-no-display”>’. get_the_time(‘c’) . ‘</span>’;
    } else {
    $modtime = ‘<span class=”date updated meta-no-display”>’. get_the_modified_time(‘c’) . ‘</span>’;
    }
    ?>
    <span class=”entry-date”><i class=”fa fa-clock-o”></i><abbr class=”published” title=”<?php echo esc_attr( get_the_date( ‘c’ ) ); ?>”><?php echo the_time( get_option( ‘date_format’ ) ); ?></abbr></span>
    <span class=”meta-no-display”>” rel=”bookmark”><?php echo the_title_attribute(); ?></span><?php echo $modtime; ?>

    Theme Author Richie KS

    (@rkcorp)

    <abbr class="published" title="<?php echo esc_attr( get_the_date( 'c' ) ); ?>"><?php echo the_time( get_option( 'date_format' ) ); ?></abbr>

    replace ‘abbr’ to ‘span’

    Thread Starter LeonWeb

    (@leonweb)

    Super! Thanks!

    And last question about post-meta.php:
    If i need this information (date + category) only main page (post-meta-home)
    And I completely remove a file “post-meta.php”
    it can break my site? It can also cause a lot of error?
    Or it’s not important for this?

    Theme Author Richie KS

    (@rkcorp)

    no need to remove or delete it, just rename it to post-meta2.php
    but i would suggest keep it but use css to hide some element for google snippet microdata pass.

    something like

    #custom span.post-author { display:none; }

    check the span class for each post meta field.

    Thread Starter LeonWeb

    (@leonweb)

    I see. Thank you very much for the advice!!!

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Remove the time information’ is closed to new replies.