Frage

I'm trying to remove the category title & category images from category view page. However, when i edit the catalog_product_view.xml from the (Infortis Ultimo) theme folder

app/design/frontend/Infortis/base/Magento_Catalog/layout/catalog_product_view.xml

it did not work, but when I edit the catalog_product_view.xml from the vendor folder

/vendor/magento/module-catalog/view/frontend/layout/catalog_category_view.xml

then it works.

I'm trying to get it done through the theme folder, how do i achieve it?

below is the code i need to add.

<referenceContainer name="columns.top">
    <referenceBlock name="page.main.title" remove="true" />
    <referenceBlock name="category.image" remove="true"/>
</referenceContainer>
<referenceContainer name="sidebar.additional" remove="true" />

Thanks!

War es hilfreich?

Lösung

It seems you are changing in wrong File.

The code you want to add is related with category image and sidebar.

app/design/frontend/Infortis/base/Magento_Catalog/layout/catalog_category_view.xml

catalog_category_view.xml is for category's product listing page whereas

catalog_product_view.xml is for Product detail page.

You are changing in different file in vendor folder to see changes but you edit "product_view" in your theme.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit magento.stackexchange
scroll top