Quick Order – Add to Cart by SKU: Magento Extension [FREE]

Quick Order – Add to Cart by SKU is a FREE Magento Extension that allows customers to directly add products to shopping cart using product SKU. This module is compatible with Magento version 1.5 and later (Magento 1.5, 1.6, 1.7, 1.8, 1.9). A Quick Order block will be displayed in left and right sidebar. This … Read more

Magento: Get Product by SKU

Here is a quick code to get / load product by its SKU in Magento. Generally we load product by its ID. Assuming product id to be ‘166’. $_productId = '166'; $_product = Mage::getModel('catalog/product')->load($_productId); But, we can also load product by its attributes, like SKU. Assuming product sku to be ‘logitechcord’. $_sku = 'logitechcord'; $_product … Read more

Magento: Get Product by SKU

Here is a quick code to get product information with SKU value. Get product information by sku // Get product by sku $sku = "microsoftnatural"; $product = Mage::getModel('catalog/product') ->loadByAttribute('sku', $sku); // print product data echo "<pre>"; print_r($product->getData()); echo "</pre>"; Get product id by sku $productIdBySku = Mage::getModel('catalog/product') ->getIdBySku('microsoftnatural'); echo $productIdBySku; Hope it helps. Thanks.