Showing posts with label Show sku by product id in OpenCart. Show all posts
Showing posts with label Show sku by product id in OpenCart. Show all posts

Wednesday, 10 September 2014

Get Product sku from product id in opencart


Get Product sku from product id in opencart

$product_sku = $this->db->query("SELECT sku FROM " . DB_PREFIX . "product WHERE product_id = '" . (int)$product['product_id'] . "'");
$product_sku = $product_sku->row['sku'];
echo $product_sku;