How to fix Google structured data errors : missing author and updated?
Topics related to RedWaves lite theme goes here.

bi888

New Member Rank
Posts: 7
Joined: Tue Sep 26, 2017 9:34 am
Display Name: bi888

How to fix Google structured data errors : missing author and updated?

linkPost by bi888 » Tue Sep 26, 2017 10:01 am

Hi!
Redwaves-lite is great.
How to fix Google structured data errors (for pages and posts) : missing author and updated?
Attachments
creen.png
creen.png (31.41 KiB) Viewed 925 times
User avatar
Asmi Khalil

Site Admin Rank
Posts: 779
Joined: Fri Jun 26, 2015 7:13 am
Display Name: Asmi Khalil
Location: Tunisia

Re: How to fix Google structured data errors : missing author and updated?

linkPost by admin » Tue Sep 26, 2017 11:04 pm

Hi Bi888,

Are you sure you are getting this error for posts too? As far as I know this error is only reported single pages because page "Author" and page "date" info are missing on these pages because pages are usually not as important as blog posts.
But if you want to fix this error on pages, open /template-parts/content-page.php and add this code right before the header closing tag </header><!-- .entry-header -->:
<div class="entry-meta page-meta-info">
	<span class="vcard author"><span class="fn"><?php the_author(); ?></span></span>
	<span class="date updated published"><?php the_time(); ?></span>
</div>
Then add this CSS code to hide author and date info from your website visitors (But they are still visible to search engines)
.page-meta-info {
	display: none;
}
Then, test the result using Google's Structured Data Testing Tool https://search.google.com/structured-da ... -tool/u/0/
I think there is a world market for maybe five computers. - IBM chairman Thomas Watson, 1943

Who is online

Users browsing this forum: No registered users and 1 guest

It is currently Mon Feb 18, 2019 10:54 am