How to add SKU in the attribute list in the More Information tab of the product view page?
-
22-03-2021 - |
Frage
I have added the following code to catalog_product_view.xml to show the SKU in the list of attributes inside the "More information" tab
<referenceBlock name="product.info.details">
<referenceBlock name="product.attributes">
<arguments>
<argument name="at_call" xsi:type="string">getSku</argument>
<argument name="at_code" xsi:type="string">sku</argument>
<argument name="css_class" xsi:type="string">sku</argument>
</arguments>
</referenceBlock>
</referenceBlock>
The other customizations in the file are visible, but not this one. Any idea?
Lösung
You don't need to do anything like that
You just follow below step to display sku in More Information tab on product view page
- Go to Stores -> Attributes -> Product
- Search SKU attribute and edit it
- Go to Storefront Properties tab and change Visible on Catalog Pages on Storefront value from No to Yes
Result :
Note : Flush cache and check
Hope this will help you
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit magento.stackexchange