The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

How do I remove dates from certain posts? (3 posts)

  1. JamesDowen
    Posted 5 years ago #

    My new WordPress website has a number of posts now but there are certain posts I want the post date to be removed from. My site has things like news, reviews and biographies but I want dates to be removed from biographies as these are always been edited and I don't want them to look 'out of date'. Is there a way of removing the post date from certain posts or categories? Maybe a plugin or by editing some code?

  2. Michael
    Forum Moderator
    Posted 5 years ago #

    you could wrap the date output code into a conditional statement using in_category('biographies') or so, assuming that the category is specific to these posts;


    <?php if( !is_category('biographies') ) /*the existing date output code, for instance:*/ the_date(); ?>

    use the existing code as a starting point.

  3. JamesDowen
    Posted 5 years ago #

    I'm no good with PHP could you explain this to me in easy steps please.

Topic Closed

This topic has been closed to new replies.

About this Topic