• Resolved robbieray

    (@robbieray)


    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)
  • Mohammed Mazhar

    (@bornvirtual)

    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)

    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.

    Thread Starter robbieray

    (@robbieray)

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

    Thread Starter robbieray

    (@robbieray)

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

    WPyogi

    (@wpyogi)

    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.

    Thread Starter robbieray

    (@robbieray)

    Anyone able to do it for me? im lost here

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and 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.

    Thread Starter robbieray

    (@robbieray)

    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)

    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.

    Thread Starter robbieray

    (@robbieray)

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

    WPyogi

    (@wpyogi)

    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)

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

    Thread Starter robbieray

    (@robbieray)

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

    WPyogi

    (@wpyogi)

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

    Thread Starter robbieray

    (@robbieray)

    Thanks your a star !

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