array – Yoast schema date modified
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It only takes a minute to sign up.
Anybody can ask a question
Anybody can answer
The best answers are voted up and rise to the top
Asked
Viewed
3 times
Trying to get the yoast date modified pulled from the json schema script for each post or page with the correct date and time format needed for metatags. Can someone help me with this?
Thank you
<?php
$date = get_post_meta(get_the_ID(), 'date_modified', true);
$header = array(
//Home
"15" => array(
"date" => "$date"
),
)
?>
Richard is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
default
Leave an answer