WordPress.org

Support

Support » How-To and Troubleshooting » [Resolved] Hiding dates in posts

[Resolved] Hiding dates in posts

  • Hi, is there a plugin or something that can hide the date a post was made? i read about something but couldnt find the code to delete in my theme , thanks

Viewing 15 replies - 1 through 15 (of 17 total)
  • Removing the date from wordpress post is very simple, all you have to do is search for these lines of code in your theme file and delete them.
    Lines to delete:

    <?php the_date(); ?>
    or this function
    <?php the_time(); ?>

    Or you can use some plugins also. You can also read the entire tutorial on this topic Remove date from WordPress posts

    Hope this solves your problem, buddy

    WPyogi

    @wpyogi

    Forum Moderator

    Be sure that you are not editing theme files directly — use a child theme so you won’t lose any change when the theme is updated.

    Thanks Mazhar , will take a look hopefully i wont mess up lol

    I tried the plugin and now it states 15666 daysago posted !

    WPyogi

    @wpyogi

    Forum Moderator

    The easier way to do what you want is to use CSS “display: none;” to hide the date from displaying on the page. You need to use the class or ID for the date element as the selector for that CSS. If you post a link to your site, someone can likely be more specific. But again, make a child theme or use a custom CSS option or plug-in. Modifying theme files will create major problems for you down the road.

    Anyone able to do it for me? im lost here

    Moderator Jan Dembowski

    @jdembowski

    Volunteer Mod. & Brute Squad

    Hi, is there a plugin or something that can hide the date a post was made?

    WPyogi’s advice is on target, you really want to do it with a child theme and preferably with CSS as that’s often easiest.

    Which theme is it? If you are using one from the WordPress theme repo here then someone may be able to provide you some specific advice.

    Hi the theme is travel press ,got to be honest its above me ..im one of the saddos that uses WordPress but dont fully understand this thanks pal

    WPyogi

    @wpyogi

    Forum Moderator

    Unless you post a link to your site, it’s impossible to give specific help. There seem to be quite a few themes with that name. If it’s a commercial theme, you’ll need to get help from the vendor.

    Hi the link is http://www.whatsonbenidorm.com , i did have a plugin but the date stayed at 15666 days posted

    WPyogi

    @wpyogi

    Forum Moderator

    As noted above, you should not make any changes to theme files — so use a custom CSS plug-in, option or a child theme. Then add this to the new CSS section/file:

    .entry-meta {
       display: none !important;
    }
    WPyogi

    @wpyogi

    Forum Moderator

    Looks like your theme already has a custom.css file — so use that.

    Hi appreciate your time on this, do i just add that code to the custom.css file? thanks again

    WPyogi

    @wpyogi

    Forum Moderator

    Yep, and then be sure to clean any browser or other caches.

    Thanks your a star !

Viewing 15 replies - 1 through 15 (of 17 total)
  • The topic ‘[Resolved] Hiding dates in posts’ is closed to new replies.