I can deactivate one of the structured data generations. But I need a full one. I need your structured data generation with my yoast seo compatible changed or I need to at your “AggregateRating content” to the structured data generator from my theme.
Would be nice, when you can add some more yoast compatibility, then i would simply deactivate the structure data generation in my thema.
Following changes would be nice:
1. You use “get_the_title” for generate the headline for a Blog Posting-
Would be nice when you use “wp_title( ”, false, ‘right’ )”. When I am right, it’s most of the time the same. But when some plugins like yoast seo change the original tile, with “wp_title( ”, false, ‘right’ )” you get the changed title. And I think this is what we want to read in the structured data.
In your code:
$review_name = wp_title( '', false, 'right' );
2. Please add a “description” in your structured data schema
It’s compatbile and nice to have:
https://developers.google.com/search/docs/data-types/articles
Text; recommended (AMP), ignored (non-AMP)
A short description of the article.
Yoast Seo Users have the small article description, you can check and read it like this:
if (class_exists('WPSEO_Meta')) {
$rich_snippet["description"] = WPSEO_Meta::get_value( 'metadesc' );
}
I think it’s good to have it in your structured data also.
And nice to have 1.
Would be nice to have dateModified diretly after datePublished, and not to have headline between of it when it is a BlogPosting
and nice to have 2.
images have to be “Images should be at least 696 pixels wide.” to prevent error on google structured data check.
See on https://developers.google.com/search/docs/data-types/articles
image
ImageObject; required (AMP), recommended (non-AMP)
(…) Images should be at least 696 pixels wide.
Would be nice, when you can stretch the width to this miniumum, when the fetaures image is not fullfill its requirments. At the momentan you simple do “”width” => $post_image_size[0],” but it would be nice, when you check if the image is smaller then 696px and if it is, strecht height and size to this minimum.
Bet regards and big thanks
Manni
-
This reply was modified 9 years, 4 months ago by
Manni79.
-
This reply was modified 9 years, 4 months ago by
Manni79.