- This topic has 10 replies, 2 voices, and was last updated 6 years ago by Tom.
-
AuthorPosts
-
February 18, 2018 at 10:10 am #499651John
Hey
I use Page Header for few post and use Last Update date but It doesn’t update in google search snippet.
In normal post It works check this structure data tool link
But In page header It doesn’t worrk check this
Missing Title and meta info here. For custom page header I disable normal page title because double title issue.
But In Live post display update date in Page header only doesn’t show search snippet.
How can I solve this?
Thanks
February 18, 2018 at 8:43 pm #499877TomLead DeveloperLead DeveloperHi there,
The data in the page header doesn’t have microdata currently. This will be addressed once the theme switches to JSON-LD instead of microdata.
For now, you may find a plugin like this useful: https://en-ca.wordpress.org/plugins/wp-structuring-markup/
February 18, 2018 at 10:09 pm #499912JohnThank you Tom
I use https://en-ca.wordpress.org/plugins/wp-structuring-markup/ plugin and choose Schema Type : Article
My article is product review.
My question, Is It write Schema Type? Or choose different type?
Check my article and confirm me.
Thanks a lot for your awesome support.
February 19, 2018 at 12:11 am #499952JohnAnd I enable only article type Schema.
screenshot link https://prnt.sc/igpxnd
Am I right? and need to enable all type?
February 19, 2018 at 9:55 am #500390TomLead DeveloperLead DeveloperYes I believe that’s right.
You can now run your post through this tool to make sure Google can see the updated date: https://search.google.com/structured-data/testing-tool/u/0/
February 27, 2018 at 12:54 pm #507266JohnHi
Tom, One week gone but still now Last Update Date not show in google search for page header element. I install this https://en-ca.wordpress.org/plugins/wp-structuring-markup/ with your way but why not work? Still show publish date in google search.Please take a look this issue.
February 27, 2018 at 9:26 pm #507519TomLead DeveloperLead DeveloperDid you run your site through the Google testing tool?: https://search.google.com/structured-data/testing-tool/u/0/
Does it recognize the updated date?
February 28, 2018 at 5:25 am #507785JohnYup, Run and see Published Date and Modified Date Both Show on Article Section in Google structure data testing tool. Please check below screenshots.
Google Structure Data testing tool Screenshot Link https://prnt.sc/ikwcdz
Google Search page Screenshot link – https://prnt.sc/ikwdjx
I already provide one of post link in secret area. you can check also.
Please Help me
February 28, 2018 at 10:12 pm #508523TomLead DeveloperLead DeveloperSince Google is picking it up, it’s usually just up to them on when they decide to show it.
You could try creating a shortcode which displays the updated date before the published date.
add_shortcode( 'updated_date', 'tu_updated_date' ); function tu_updated_date() { $time_string = ''; if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) { $time_string .= '<time class="updated" datetime="%3$s" itemprop="dateModified">%4$s</time>'; } $time_string .= '<time class="entry-date published" datetime="%1$s" itemprop="datePublished">%2$s</time>'; $time_string = sprintf( $time_string, esc_attr( get_the_date( 'c' ) ), esc_html( get_the_date() ), esc_attr( get_the_modified_date( 'c' ) ), esc_html( get_the_modified_date() ) ); $date = sprintf( '<a href="%1$s" title="%2$s" rel="bookmark">%3$s</a>', esc_url( get_permalink() ), esc_attr( get_the_time() ), $time_string ); return $date; }
Then add this in the Page Header:
[updated_date]
March 30, 2018 at 1:34 am #535894JohnHey Tom
I applied your provide code in functions.php and used [updated_date] shortcode in page header almost one month ago but still show published date on google search.
Could you please check again?
Thanks
March 30, 2018 at 9:11 am #536318TomLead DeveloperLead DeveloperI’m afraid it’s just up to Google. All we can do is add the necessary HTML markup. You can run your page through their Rich Snippets tester just to make sure the markup is working.
-
AuthorPosts
- You must be logged in to reply to this topic.