Hi,
I noticed a couple of weeks ago that all my product images in Google images have the mention "out of stock".
Of course they are not out of stock, but when I check the page source of these products it says:
"offers": {
"@type": "Offer",
"priceCurrency": "USD",
"availability": "OutofStock",
"price": "800",
But in my product page, items are in stock... how can I change this? Why does my product have "availability": "OutofStock" when I have 1 in the "In Stock" field?
Is that a bug? or is there a new setting to update in Virtuemart? It is probably due to a Google update though... but it seems that every other website using virtuemart has it's products set as "in stock" in Google images, only mine is showing available products as "out of stock".
versions?
how are u producing the Google rich snippets on your site?
Hi, I don't know what you mean about google rich snippets, I don't think I have that on my website. I never setup anything between google an my website apart from the standard Google Analytics. And I never had Google images displaying the status of my items, it just started less than (I guess) a month ago or less.
without a live url no one can help you -- google is reading a snippet from somewhere
Thanks for your reply by the way.
For example, this product (and every other product) https://www.pailingemstones.com/index.php/gemstones-with-video/best-blue-zircon-online-supplier-detail
is available, has 1 item in stock, but in google images, if you search for "buy blue zircon online", you'll find it near the top, with the mention "out of stock".
But isn't the problem coming from the fact that in the "page source" of all my product pages, even if they are in stock, the code says:
"@type": "Offer",
"priceCurrency": "USD",
"availability": "OutofStock",
Isn't this what makes google mark it as "out of stock"? Isn't this the bug?
some where in your templates you have a script producing this
<script type="application/ld+json">
{
"@context": "http://schema.org/",
"@type": "Product",
"name": "Large Flawless and Shiny Blue Zircon 8.9ct",
"description":"Discount proposed for this large FL flawless 8.9ct Blue Zircon from Cambodia, best value supplier blue Zircon online. ",
"image": [
"https://pailingemstones.com/images/stories/virtuemart/product/best-blue-zircon-online-supplier-04.jpg", "https://pailingemstones.com/images/stories/virtuemart/product/best-blue-zircon-online-supplier-03.jpg", "https://pailingemstones.com/images/stories/virtuemart/product/best-blue-zircon-online-supplier-02.jpg", "https://pailingemstones.com/images/stories/virtuemart/product/best-blue-zircon-online-supplier-01.jpg", "https://pailingemstones.com/images/stories/virtuemart/product/best-blue-zircon-online-supplier-06.jpg" ],
"offers": {
"@type": "Offer",
"priceCurrency": "USD",
"availability": "OutofStock",
"price": "540",
"url": "https://www.pailingemstones.com/index.php/gemstones-main/species-families/zircon-gems/best-blue-zircon-online-supplier-detail",
"itemCondition": "NewCondition"
}
}
</script>
see:
https://search.google.com/structured-data/testing-tool#url=https%3A%2F%2Fwww.pailingemstones.com%2Findex.php%2Fgemstones-with-video%2Fbest-blue-zircon-online-supplier-detail
probably : components\com_virtuemart\sublayouts\snippets.php or an over ride
So I found
"availability": "<?php echo $stockog; ?>",
in the page you mentionned and turned it into
"availability": "InStock",
I'll wait for a few hours to see if it helps, thanks for your help.
Well I've tried to update the code from
"availability": "<?php echo $stockog; ?>",
to
"availability": "InStock",
I waited about 6 hours and Google still shows all my products as "out of stock"
Now I've changed it to
"availability": " http://schema.org/InStock",
just because I saw it on other websites, not sure it's Virtuemart or not.
But I feel that it's not going to work either... Can somebody tell me what is the syntax I should use to force availability to be "In Stock"?
Google isn't "realtime" !!!
It isn't possible that they would scan and reclass your site in 6 hours!!
Just use the https://search.google.com/structured-data/testing-tool and let Google do its thing when it does it ..
hard coded "availability": "InStock", is correct