tags:

views:

146

answers:

2
+1  Q: 

Magento framework

Hai

I build a project in magneto in my local host. I added the categories and products in admin side, but when the product displayed on the user side the SKU ID not shown? What can I do to display the sku id along with the product details?

Thanks in advance

+1  A: 

It might not be shown, because SKU is not in the template. But otherwise, if you want attribute to be shown in front-end, then it has to be turned visible from magento admin.

Go to admin and from there Catalog -> Attributes -> Manage attributes. Search for SKU attribute and open it for editing. You can change this property under Frontent Properties -> Visible on Product View Page on Front-end. Choose yes.

Alan.

Zayatzz
Thanks it's working Fine
Testadmin
+2  A: 

Open up /app/design/frontend/default/default/template/catalog/product/view.phtml

In that template, figure out where you want the SKU to be displayed, and add this:

<?php echo $this->getSku(); ?>

Magento used a lot of magic methods - so, pretty much any attribute is accessable with $this->getAttributeName;

Prattski