Google Shopping Feed: Availability Line in Source Code
Google Shopping Feed: Availability Line in Source Code
Hi y'all,
We have been receiving warning/notifications recently for our items in Google Shopping/Merchant Center because of "Availability." In our Merchant Center account, under Settings > Automatic Item Updates > Availability, it says that none of our items "are currently being updated due to certain warnings."
I called Google, and they referred me to this page for assistance, https://support.google.com/merchants/an ... 9143?hl=en, stating that the "Availability" line was missing from our source code. The code that is missing is " <meta itemprop="availability" content="http://schema.org/InStock"/>Available online"
Can someone please advise where I should enter this on the back end? Where do I find this source code? Has anyone else had this issue? We are using GOLD R8.
Thanks in advance!!
Mary
We have been receiving warning/notifications recently for our items in Google Shopping/Merchant Center because of "Availability." In our Merchant Center account, under Settings > Automatic Item Updates > Availability, it says that none of our items "are currently being updated due to certain warnings."
I called Google, and they referred me to this page for assistance, https://support.google.com/merchants/an ... 9143?hl=en, stating that the "Availability" line was missing from our source code. The code that is missing is " <meta itemprop="availability" content="http://schema.org/InStock"/>Available online"
Can someone please advise where I should enter this on the back end? Where do I find this source code? Has anyone else had this issue? We are using GOLD R8.
Thanks in advance!!
Mary
Re: Google Shopping Feed: Availability Line in Source Code
Hi Mary,
I think there may be something else going on. The availability attribute has been supported for a long time. In Gold R5, we added Google Feed support for variants, so I am not sure why you are getting an error in Gold R8. The feed is a popular feature, and if it was missing a required attribute, I think we would have heard about it from other customers.
If you open the \app_code\GoogleFeed.cs, you can easily see the 'availability' code.
Do you know if the products are variants? Have you looked at your feed file to see what is being output? It should be in the \feeds\ folder.
Thanks
Katie
I think there may be something else going on. The availability attribute has been supported for a long time. In Gold R5, we added Google Feed support for variants, so I am not sure why you are getting an error in Gold R8. The feed is a popular feature, and if it was missing a required attribute, I think we would have heard about it from other customers.
If you open the \app_code\GoogleFeed.cs, you can easily see the 'availability' code.
Do you know if the products are variants? Have you looked at your feed file to see what is being output? It should be in the \feeds\ folder.
Thanks
Katie
Thank you for choosing AbleCommerce!
http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support
http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support
Re: Google Shopping Feed: Availability Line in Source Code
Thanks, Katie. The products are not variants, and we're getting the error for all of our products, hundreds of them. I can see in the feed file "in stock" "out of stock" etc. for each product, but I'm not sure why Google Shopping isn't registering that. When I call Google to troubleshoot, they keep telling me that they are looking at my source code, and that the problem is with the source code. I'm not sure what else to do...
Re: Google Shopping Feed: Availability Line in Source Code
Hi Katie, have you heard anything back on this yet? If you have a live site demo of AbleCommerce 11, I can tell if it has all the correct schema in the most recent release. I also have a question about the rel=canonical tag for pages in a series.
Thanks!
Thanks!
Re: Google Shopping Feed: Availability Line in Source Code
From the "About microdata for Google Shopping" page I can see that:
https://support.google.com/merchants/answer/3246284
It seems that you have enabled the automatic item updates and Able Commerce do not provide the required microdata ("itemprop" for availability) at the product retail page.Specifying price, priceCurrency, and availability is required for automatic item updates.
So, you should either disable the automatic item updates, or update the product retail page and add code for above required "itemprop". To disable the disable automatic item updates check the "Reverting an automatic update" section at following link:<meta itemprop="availability" content="http://schema.org/InStock"/>Available online
https://support.google.com/merchants/answer/3246284
Thanks for your support
Naveed Ashraf
.com
AbleCommerce Help Center
AbleCommerce Developer WIKI
Follow us on Twitter
Naveed Ashraf
.com
AbleCommerce Help Center
AbleCommerce Developer WIKI
Follow us on Twitter
Re: Google Shopping Feed: Availability Line in Source Code
Thanks, Naveed. Does AbleCommerce provide the required mircrodata in the most recent version, R11?
Re: Google Shopping Feed: Availability Line in Source Code
You can make the following updates to emit required details. First edit the ConLib/BuyProductDialog.ascx.cs and locate following line of code
and update it like
Then locate following line of code
and update it like
Then recheck the merchant center and see if it makes any difference.
Code: Select all
InventoryDetailsPanel.Controls.Add(new LiteralControl(inStockMessage));
Code: Select all
InventoryDetailsPanel.Controls.Add(new LiteralControl("<meta itemprop=\"availability\" content=\"http://schema.org/InStock\"/>"));
InventoryDetailsPanel.Controls.Add(new LiteralControl(inStockMessage));
Code: Select all
InventoryDetailsPanel.Controls.Add(new LiteralControl(outOfStockMessage));
Code: Select all
InventoryDetailsPanel.Controls.Add(new LiteralControl("<meta itemprop=\"availability\" content=\"http://schema.org/OutOfStock\"/>"));
InventoryDetailsPanel.Controls.Add(new LiteralControl(outOfStockMessage));
Re: Google Shopping Feed: Availability Line in Source Code
I am sorry to say that AbleCommerce R11 do not support this as well, so you should try the workaround posted by Mazhar.Does AbleCommerce provide the required mircrodata in the most recent version, R11?
Thanks for your support
Naveed Ashraf
.com
AbleCommerce Help Center
AbleCommerce Developer WIKI
Follow us on Twitter
Naveed Ashraf
.com
AbleCommerce Help Center
AbleCommerce Developer WIKI
Follow us on Twitter
Re: Google Shopping Feed: Availability Line in Source Code
No, but I requested a feature enhancement so it will be supported in our next version. I did not realize you were using an Automatic Update option.Does AbleCommerce provide the required mircrodata in the most recent version, R11?
Thank you for choosing AbleCommerce!
http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support
http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support
Re: Google Shopping Feed: Availability Line in Source Code
Thanks, y'all!
Re: Google Shopping Feed: Availability Line in Source Code
Thank you for the code, Mazhar. That did get the price and availability schemas to show up for Google. Google also requires the currency schema. Please let me know how we can add this to the schemas. It doesn't matter to us if we hard code it, as we only sell in one currency (USD).
Rick
Rick
Rick Morris
Brewhaus (America) Inc.
Hot Sauce Depot
Brewhaus (America) Inc.
Hot Sauce Depot
Re: Google Shopping Feed: Availability Line in Source Code
Edit ConLib/Utility/ProductPrice.ascx file and locate following codeBrewhaus wrote:Thank you for the code, Mazhar. That did get the price and availability schemas to show up for Google. Google also requires the currency schema. Please let me know how we can add this to the schemas. It doesn't matter to us if we hard code it, as we only sell in one currency (USD).
Rick
Code: Select all
<%if (IncludeRichSnippetsWraper)
{ %>
</span>
<%} %>
Code: Select all
<%if (IncludeRichSnippetsWraper)
{ %>
<meta itemprop="priceCurrency" content="USD" />
</span>
<%} %>
Re: Google Shopping Feed: Availability Line in Source Code
Hi mazhar,
We made the changes but now we're getting errors for the price and availability schemas for the product pages, which you can see when you test it with Google's Structured Data Testing Tool. I'm unable to upload a screenshot, but if you visit developers.google.com/structured-data/testing-tool/ and enter http://www.hotsaucedepot.com/Daves-Insa ... Sauce.aspx for the URL, you will see the exact errors.
How can we fix this?
Thank you,
Mary
We made the changes but now we're getting errors for the price and availability schemas for the product pages, which you can see when you test it with Google's Structured Data Testing Tool. I'm unable to upload a screenshot, but if you visit developers.google.com/structured-data/testing-tool/ and enter http://www.hotsaucedepot.com/Daves-Insa ... Sauce.aspx for the URL, you will see the exact errors.
How can we fix this?
Thank you,
Mary
Re: Google Shopping Feed: Availability Line in Source Code
I have checked the issues with your mentioned page http://www.hotsaucedepot.com/Daves-Insa ... Sauce.aspx using the developers.google.com/structured-data/testing-tool/, one issue is about missing price, and related to following code lines:
The generated code is not correct and it should be something like:
There seems a problem with the changes you made while editing ConLib/Utility/ProductPrice.ascx file. I suggest to revert ALL the earlier changes suggested by Mazhar. I am attaching updated files for reference, which you can use to compare and fix your code. Here I explain the required changes:
1. Edit the ~/ConLib/BuyProductDialog.ascx.cs file and add the following function just above "Page_Init" function. This will return the product availability status:
2. Edit the ~/ConLib/BuyProductDialog.ascx file and locate the following code:
And replace with:
So, we just added "<meta itemprop="availability" content="<%=ProductAvailabilityStatus%>" />" code under the <uc:ProductPrice/> tag.
3. Edit the ConLib/Utility/ProductPrice.ascx file and locate the following code:
And replace with
So, we just added a new line of code " <meta itemprop="priceCurrency" content="USD" />".
Save changes and compile the project.
Code: Select all
<span itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<meta itemprop="priceCurrency" content="USD" />
</span>
$5.49
</span>
Code: Select all
<span itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<span itemprop="price">$5.49</span>
<meta itemprop="priceCurrency" content="USD" />
<meta itemprop="availability" content="http://schema.org/InStock"/>
</span>
1. Edit the ~/ConLib/BuyProductDialog.ascx.cs file and add the following function just above "Page_Init" function. This will return the product availability status:
Code: Select all
protected string ProductAvailabilityStatus
{
get
{
string inStockValue = "http://schema.org/InStock";
string outStockValue = "http://schema.org/OutOfStock";
if (!AbleContext.Current.Store.Settings.EnableInventory || _Product.InventoryMode == InventoryMode.None
|| _Product.AllowBackorder)
return inStockValue;
bool allProductOptionsSelected = (_SelectedOptionChoices.Count == _Product.ProductOptions.Count);
bool requiredKitOptionsSelected = AbleCommerce.Code.ProductHelper.RequiredKitOptionsSelected(_Product, _SelectedKitProducts);
if (allProductOptionsSelected && requiredKitOptionsSelected)
{
string optionList = ProductVariantDataSource.GetOptionList(_ProductId, _SelectedOptionChoices, true);
IInventoryManager inventoryManager = AbleContext.Resolve<IInventoryManager>();
InventoryManagerData inv = inventoryManager.CheckStock(_ProductId, optionList, _SelectedKitProducts);
if (inv.InStock > 0)
{
return inStockValue;
}
else
{
return outStockValue;
}
}
return inStockValue;
}
}
Code: Select all
<span itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<uc:ProductPrice ID="OurPrice" runat="server" EnableDefaultKitProducts="false" HideZeroPrice="false" IncludeRichSnippetsWraper="True" />
</span>
Code: Select all
<span itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<uc:ProductPrice ID="OurPrice" runat="server" EnableDefaultKitProducts="false" HideZeroPrice="false" IncludeRichSnippetsWraper="True" />
<meta itemprop="availability" content="<%=ProductAvailabilityStatus%>" />
</span>
3. Edit the ConLib/Utility/ProductPrice.ascx file and locate the following code:
Code: Select all
<%if (IncludeRichSnippetsWraper)
{ %>
<span itemprop="price">
<%} %>
<asp:Literal ID="Price" runat="server"></asp:Literal>
<%if (IncludeRichSnippetsWraper)
{ %>
</span>
<%} %>
And replace with
Code: Select all
<%if (IncludeRichSnippetsWraper)
{ %>
<span itemprop="price">
<%} %>
<asp:Literal ID="Price" runat="server"></asp:Literal>
<%if (IncludeRichSnippetsWraper)
{ %>
</span>
<meta itemprop="priceCurrency" content="USD" />
<%} %>
Save changes and compile the project.
Thanks for your support
Naveed Ashraf
.com
AbleCommerce Help Center
AbleCommerce Developer WIKI
Follow us on Twitter
Naveed Ashraf
.com
AbleCommerce Help Center
AbleCommerce Developer WIKI
Follow us on Twitter
Re: Google Shopping Feed: Availability Line in Source Code
Thank you, Naveed. I will make the changes and have Mary check it all.
Rick
Rick
Rick Morris
Brewhaus (America) Inc.
Hot Sauce Depot
Brewhaus (America) Inc.
Hot Sauce Depot
Re: Google Shopping Feed: Availability Line in Source Code
It works! Thank you, Naveed, you're awesome!
Re: Google Shopping Feed: Availability Line in Source Code
I just did it and it solved the priceCurrency error but I still get the error:
$1,339.00 (The property $1,339.00 is not a valid price specification.
Contractor's Solutions
www. contractors-solutions.net
www. contractors-solutions.net
- xplosi0n1
- Lieutenant, Jr. Grade (LT JG)
- Posts: 30
- Joined: Mon Nov 30, 2009 10:54 am
- Location: Dayton, OH
- Contact:
Re: Google Shopping Feed: Availability Line in Source Code
Hello All,
Can someone please circle back to this post and see if there is a way to correct this last issue.
$169.95 (The property $169.95 is not a valid price specification.
I have followed all the steps from above from both Mazhar and Naveed and still get this error from the Google Structure Data Testing Tool
See test here - https://search.google.com/structured-da ... Drive.aspx
Any help will be appreciated. We are using Gold R10
Can someone please circle back to this post and see if there is a way to correct this last issue.
$169.95 (The property $169.95 is not a valid price specification.
I have followed all the steps from above from both Mazhar and Naveed and still get this error from the Google Structure Data Testing Tool
See test here - https://search.google.com/structured-da ... Drive.aspx
Any help will be appreciated. We are using Gold R10
Thanks,
Mike
CheapBowlingBalls.com
3204 Woodman Drive
Kettering, OH 45420
937.559.1541
mikeh@cheapbowlingballs.com
www.cheapbowlingballs.com
Mike
CheapBowlingBalls.com
3204 Woodman Drive
Kettering, OH 45420
937.559.1541
mikeh@cheapbowlingballs.com
www.cheapbowlingballs.com
- jmestep
- AbleCommerce Angel
- Posts: 8164
- Joined: Sun Feb 29, 2004 8:04 pm
- Location: Dayton, OH
- Contact:
Re: Google Shopping Feed: Availability Line in Source Code
You need to move the dollar sign outside the tag. Then change the price display in the code behind to something like .LSCurrencyFormat("ulcf") or .ToString("F2") - off the top of my head.
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
- xplosi0n1
- Lieutenant, Jr. Grade (LT JG)
- Posts: 30
- Joined: Mon Nov 30, 2009 10:54 am
- Location: Dayton, OH
- Contact:
Re: Google Shopping Feed: Availability Line in Source Code
Judy,
Can you elaborate on what file this would be done under, I can't seem to locate where to do this at.
Can you elaborate on what file this would be done under, I can't seem to locate where to do this at.
Thanks,
Mike
CheapBowlingBalls.com
3204 Woodman Drive
Kettering, OH 45420
937.559.1541
mikeh@cheapbowlingballs.com
www.cheapbowlingballs.com
Mike
CheapBowlingBalls.com
3204 Woodman Drive
Kettering, OH 45420
937.559.1541
mikeh@cheapbowlingballs.com
www.cheapbowlingballs.com
- jmestep
- AbleCommerce Angel
- Posts: 8164
- Joined: Sun Feb 29, 2004 8:04 pm
- Location: Dayton, OH
- Contact:
Re: Google Shopping Feed: Availability Line in Source Code
It looks like on your site it is in ConLib/BuyProductDialog. You can search for itemprop="price".
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
- xplosi0n1
- Lieutenant, Jr. Grade (LT JG)
- Posts: 30
- Joined: Mon Nov 30, 2009 10:54 am
- Location: Dayton, OH
- Contact:
Re: Google Shopping Feed: Availability Line in Source Code
Judy,
Here is all the pricing code I could locate on the BuyProductDialog.ascx
Here is all the pricing code I could locate on the BuyProductDialog.ascx
Code: Select all
<%--<tr id="trRegPrice" runat="server" enableviewstate="false">
<th class="rowHeader">
<asp:Localize ID="RegPriceLocalize" runat="server" Text="Reg. Price:" EnableViewState="false"></asp:Localize>
</th>
<td>
<asp:Label ID="RegPrice" runat="server" SkinID="MSRP" EnableViewState="false"></asp:Label>
</td>
</tr>--%>
<%--<tr id="trOurPrice" runat="server" EnableViewState="false" class="priceLabel">
<th class="rowHeader">
<asp:Localize ID="OurPriceLocalize" runat="server" Text="Our Price:" EnableViewState="false"></asp:Localize>
</th>
<td>
<span itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<uc:ProductPrice ID="OurPrice" runat="server" EnableDefaultKitProducts="false" HideZeroPrice="false" IncludeRichSnippetsWraper="True" />
</span>
</td>
</tr>--%>
<tr id="trVariablePrice" runat="server" enableviewstate="false">
<th class="rowHeader">
<asp:Localize ID="VariablePriceLabel" runat="server" Text="Enter Price:" EnableViewState="false"></asp:Localize>
</th>
<td>
<asp:TextBox ID="VariablePrice" runat="server" MaxLength="8" Width="60px" ValidationGroup="AddToBasket"></asp:TextBox>
<asp:PlaceHolder ID="phVariablePrice" runat="server"></asp:PlaceHolder>
</td>
</tr>
Thanks,
Mike
CheapBowlingBalls.com
3204 Woodman Drive
Kettering, OH 45420
937.559.1541
mikeh@cheapbowlingballs.com
www.cheapbowlingballs.com
Mike
CheapBowlingBalls.com
3204 Woodman Drive
Kettering, OH 45420
937.559.1541
mikeh@cheapbowlingballs.com
www.cheapbowlingballs.com
- jmestep
- AbleCommerce Angel
- Posts: 8164
- Joined: Sun Feb 29, 2004 8:04 pm
- Location: Dayton, OH
- Contact:
Re: Google Shopping Feed: Availability Line in Source Code
At this point, I don't know what to say. It looks like the pricing display is commented out so it must be somewhere else.
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Re: Google Shopping Feed: Availability Line in Source Code
I just noticed that meta itemprop='url' is pulling the http version of the URL and not the HTTPS. How can we fix this? Also, how do we fix the dollar sign issue in R12?