I’m using the following code: "image": "<?php $imageschema = wp_get_attachment_image_src(get_field('imagen'), 'thumbnail'); echo $imageschema; ?>",
Which does outputs the correct image url in the code source but unfortunately it doesn’t display the image in google results nor in in Google preview link test: https://search.google.com/test/rich-results
Those are warnings, not errors. They are because you’re not including “Offers” or “Performers.”
This is for the Events scheme, and Google may or may not require those to be included for it to be valid (they may be optional).
The image isn’t supposed to “Display” you’re just telling it what the URL is for the Event. If Google chooses to display this on Google (when someone does a search for Events), they can use the URL to show it at that point.
In this case, it looks to be working properly.
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users