Remove time, author and comment from blog page and single posts

This topic has 4 replies, 2 voices, and was last updated 8 years, 1 months ago ago by Robert Hall

  • Avatar: Rita
    Rita
    Participant
    March 19, 2016 at 00:21

    I turned off the byline in theme options, but it removed the date also so I’ve been trying to remove what I thought was the code for the time, author and comment from theme-functions.php

    <?php the_time(get_option(‘time_format’)); ?>
    <?php _e(‘by’, ETHEME_DOMAIN); ?> <?php the_author_posts_link(); ?>
    <?php // Display Comments

    That didn’t work as I’m now thinking may be b/c it was only for the post slider? and maybe b/c I’m using the child them for woopress?

    I want to keep the date, but remove the time, author and comment count from both the blog page/archive page and single post page. I just can’t seem to figure it out on my own what to remove or what to place into the child theme functions.php file.

    I managed to remove the author from the recent posts widget ok.

    Appreciate you help.

    3 Answers
    Avatar: Robert Hall
    Robert Hall
    Support staff
    March 19, 2016 at 09:52

    Hello,

    In this case you should edit \wp-content\themes\woopress\content.php file and comment out the following code on line 79-89

    <?php _e('at', ETHEME_DOMAIN) ?> 
    <?php the_time(get_option('time_format')); ?>
    <?php _e('by', ETHEME_DOMAIN);?> <span class="vcard"> <span class="fn"><?php the_author_posts_link(); ?></span></span>
    <?php // Display Comments 
    	
    if(comments_open() && !post_password_required()) {
    echo ' / ';
    comments_popup_link('0', '1 Comment', '% Comments', 'post-comments-count');
    }
    ?>

    and the same thing you should do in \wp-content\themes\woopress\single.php file on line 93-103

    Please copy these files into woopress-child folder and make changes there.

    Regards,
    Robert Hall

    Avatar: Rita
    Rita
    Participant
    March 21, 2016 at 14:37

    this worked. thank you.

    Avatar: Robert Hall
    Robert Hall
    Support staff
    March 21, 2016 at 15:00

    Hello,

    You’re welcome!

    Regards,
    Robert Hall

  • Viewing 4 results - 1 through 4 (of 4 total)

The issue related to '‘remove time, author and comment from blog page and single posts’' has been successfully resolved, and the topic is now closed for further responses

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.