Prestashop SEO Structured Data Settings

Prestashop SEO Structured Data Settings

Microdata helps search engines find content on the site faster and understand it correctly. The introduction of micro-markup is to use tags and attributes, the purpose of which is to structure information.

Let's look at how to embed the code in the classic theme

First, let's go to the site

Google Search Center.

We need to check three pages of the site this is the main page category page and product page. Start from the home page you need to copy the link and paste it into the URL field and press to button RUN TEST

Prestashop SEO

After clicking after a while you will see two columns. In the left column you will have the code of the entire site and on the right, found ERRORS, WARNINGS and ITEMS

Prestashop SEO

Then you need to click on the product with an error

Prestashop SEO

now you need to go through your FTP to the site in the folder themes\classic\templates\catalog\_partials\miniatures\ and open file product.tpl. You will see the code of the product block

Prestashop SEO

And as in the Structured Data Testing Tool we see the first error related to availability ( whether in stock or not )

In the product.tpl file between lines 72 and 73, insert the following code <link itemprop="availability" href="{$ product.seo_availability}" />

Prestashop SEO

And reload your site page, as you can see this error disappeared, it means that google bot saw the availability meta tag and displayed it. We will continue to correct errors.

Prestashop SEO

Now we need to fix priceValidUntil. If you have a promotional item with a discount that ends on a specific day? - Then you would like to fill in this variable. If you have an item with a standard price and you do not know when the price will change - Then you don't need to fill this variable. After you have inserted the code for availability, you need to enter <meta itemprop="priceValidUntil" content="2029-12-31"> after it.

Prestashop SEO

Also reload the site page and see if the error is gone how do we see that the error is gone

Prestashop SEO

then we see the URL error (Item url.) After priceValidUntil, add the code <link itemprop="url" href="{$ product.link}" />

Prestashop SEO

And again reload the site page, how do we see that the error is gone

Prestashop SEO

AggregateRating we will skip for now, we don't have much left. Now you need to fix the error associated with description. In the same product.tpl file lines 79 add code

<meta itemprop="description" content="{$product.name}"/>

Prestashop SEO

And reload the site page. We see that the description error is gone.

Prestashop SEO

For how many brands are not used on the main page of the site, we will not indicate it, but if you need it, specify it after the description <meta itemprop="brand" content="{$product->manufacturer_name|escape:'htmlall':'UTF-8'}"/> or use a module for this. Next, we will fix the error related to image. To do this, in the same product.tpl file on line 33 in the img tag we need to add itemprop = "image" between lines 36 and 38

Prestashop SEO

Prestashop SEO

To fix the sku and mpn error you need to add in the same product.tpl file. Insert code between lines 28 and 29

<meta itemprop="sku" content="{$product.id_product}" />

<meta itemprop="mpn" content="{$product.reference}" />

Prestashop SEO

But for the reference, you need to specify the value in the back office in the product settings so that the value is used and the error is eliminated

Prestashop SEO

Prestashop SEO

Prestashop SEO Structured Data Settings

Prestashop Team

on Sep 30, 2021

Chat with us on WhatsApp