Home › Forums › Support › Display date on certain post › Reply To: Display date on certain post
May 7, 2016 at 11:02 pm
#192615
Tom
Lead Developer
Lead Developer
You could do something like this using the generate_post_date filter:
add_filter( 'generate_post_date','generate_show_specific_date' );
function generate_show_specific_date()
{
// If post ID is 10, show the date
if ( is_single( 10 ) )
return true;
// Otherwise, remove the date
return false;
}
Adding PHP: https://generatepress.com/knowledgebase/adding-php-functions/