Перейти к содержимому


Ошибка Микроразметки < Отсутствует Поле "availability" >

availability микроразметка

  • Авторизуйтесь для ответа в теме
В этой теме нет ответов

#1 metry

metry

    Активный участник

  • Модераторы
  • 591 сообщений

Отправлено 30 Август 2019 - 12:50



Для внесения изменений зайдите в Редактор шаблонов-->HTML и найдите:


                                    <meta itemprop="priceCurrency" content="{CURRENCY_CHAR_CODE}"/>
                                    {% IF index_page_goods.MIN_PRICE_NOW_WITHOUT_DISCOUNT>index_page_goods.MIN_PRICE_NOW %}


замените на:


                                    <meta itemprop="availability" content="{% IF SETTINGS_GOODS_DONT_PUT_TO_CART_MORE_THAN_AVAILABLE && index_page_goods.MAX_REST_VALUE==0 %}https://schema.org/OutOfStock{% ELSE %}https://schema.org/InStock{% ENDIF %}" />
                                    <meta itemprop="priceCurrency" content="{CURRENCY_CHAR_CODE}"/>
                                    {% IF index_page_goods.MIN_PRICE_NOW_WITHOUT_DISCOUNT>index_page_goods.MIN_PRICE_NOW %}


далее найдите:


                                    <meta itemprop="priceCurrency" content="{CURRENCY_CHAR_CODE}"/>
                                    {% IF index_page_new_goods.MIN_PRICE_NOW_WITHOUT_DISCOUNT>index_page_new_goods.MIN_PRICE_NOW %}


замените на:


                                    <meta itemprop="availability" content="{% IF SETTINGS_GOODS_DONT_PUT_TO_CART_MORE_THAN_AVAILABLE && index_page_new_goods.MAX_REST_VALUE==0 %}https://schema.org/OutOfStock{% ELSE %}https://schema.org/InStock{% ENDIF %}"/>
                                    <meta itemprop="priceCurrency" content="{CURRENCY_CHAR_CODE}"/>
                                    {% IF index_page_new_goods.MIN_PRICE_NOW_WITHOUT_DISCOUNT>index_page_new_goods.MIN_PRICE_NOW %}


далее найдите:


                                    <meta itemprop="priceCurrency" content="{CURRENCY_CHAR_CODE}"/>
                                    {% IF index_page_favorites_goods.MIN_PRICE_NOW_WITHOUT_DISCOUNT>index_page_favorites_goods.MIN_PRICE_NOW %}


замените на:


                                    <meta itemprop="availability" content="{% IF SETTINGS_GOODS_DONT_PUT_TO_CART_MORE_THAN_AVAILABLE && index_page_favorites_goods.MAX_REST_VALUE==0  %}https://schema.org/OutOfStock{% ELSE %}https://schema.org/InStock{% ENDIF %}" />
                                    <meta itemprop="priceCurrency" content="{CURRENCY_CHAR_CODE}"/>
                                    {% IF index_page_favorites_goods.MIN_PRICE_NOW_WITHOUT_DISCOUNT>index_page_favorites_goods.MIN_PRICE_NOW %}


далее найдите:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price">{index_page_goods.MIN_PRICE_NOW | money_format}</span>


замените на:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price" content="{index_page_goods.MIN_PRICE_NOW}">{index_page_goods.MIN_PRICE_NOW | money_format}</span>


далее найдите:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price">{index_page_new_goods.MIN_PRICE_NOW | money_format}</span>


замените на:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price" content="{index_page_new_goods.MIN_PRICE_NOW}">{index_page_new_goods.MIN_PRICE_NOW | money_format}</span>


далее найдите:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price">{index_page_favorites_goods.MIN_PRICE_NOW | money_format}</span>


замените на:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price" content="{index_page_favorites_goods.MIN_PRICE_NOW}">{index_page_favorites_goods.MIN_PRICE_NOW | money_format}</span>


далее зайдите в Редактор шаблонов-->Товары и найдите:


                    <div class="product-info">
                      <div class="product-name"><a href="{goods.URL | url_amp}" title="{goods.NAME}" itemprop="url">{goods.NAME}</a></div>
                      <meta itemprop="name" content="{goods.NAME}">
                      <div class="price-box" itemprop="offers" itemscope itemtype="https://schema.org/Offer">


и после него вставьте:


<meta itemprop="availability" content="{% IF SETTINGS_GOODS_DONT_PUT_TO_CART_MORE_THAN_AVAILABLE && goods.MAX_REST_VALUE==0 %}https://schema.org/OutOfStock{% ELSE %}https://schema.org/InStock{% ENDIF %}"/>


далее найдите:


                      <div class="product-name"><a href="{goods.URL_MIN_PRICE_NOW | url_amp}" title="{goods.NAME}" itemprop="url">{goods.NAME}</a></div>
                      <meta itemprop="name" content="{goods.NAME}">
                      <meta itemprop="description" content="{% IF goods.DESCRIPTION_SHORT %}{goods.DESCRIPTION_SHORT}{% ELSE %}Описание отсутствует{% ENDIF %}">
                      <div class="price-box" itemprop="offers" itemscope itemtype="https://schema.org/Offer">


и после него вставьте:


<meta itemprop="availability" content="{% IF SETTINGS_GOODS_DONT_PUT_TO_CART_MORE_THAN_AVAILABLE && goods.MAX_REST_VALUE==0 %}https://schema.org/OutOfStock{% ELSE %}https://schema.org/InStock{% ENDIF %}"/>


далее найдите:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price">{goods.MIN_PRICE_NOW | money_format}</span>


замените на:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price" content="{goods.MIN_PRICE_NOW}"  >{goods.MIN_PRICE_NOW | money_format}</span>


далее снова найдите:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price">{goods.MIN_PRICE_NOW | money_format}</span>


замените на:


<span class="price {CURRENCY_CHAR_CODE}" itemprop="price" content="{goods.MIN_PRICE_NOW}"  >{goods.MIN_PRICE_NOW | money_format}</span>






Количество пользователей, читающих эту тему: 0

0 пользователей, 0 гостей, 0 анонимных