Category Archive: Technology

Jun 01

Wishlist in Magento

Wishlist by customer id in Magento $wishList = Mage::getSingleton(‘wishlist/wishlist’)->loadByCustomer($custid); OR $wishList = Mage::getSingleton(‘wishlist/wishlist’)->loadByCustomer($customer); $wishListItemCollection = $wishList->getItemCollection(); if (count($wishListItemCollection)) { $arrproduct = array(); foreach ($wishListItemCollection as $item) { $product = $item->getProduct(); $arrproduct  [‘product’][] =array($product->getName(),$product->getPrice(),$product->getQuantity(),Mage::getBaseUrl(‘media’) . ‘catalog/product/’ . Mage::getModel(‘catalog/product’)->load($product->getId())->getThumbnail()); } } print_r($arrproduct );

Jun 01

Product Details in Magento

Product details by product id in magento $prod = Mage::getModel(‘catalog/product’); $_product = $prod->load($productid); // Enter your Product Id in $product_id echo $_product->getName(); //get product’s short description echo $_product->getShortDescription(); //get Product’s Long Description echo $_product->getDescription(); //get Product’s Regular Price echo $_product->getPrice(); //get Product’s Special price echo $_product->getSpecialPrice(); //get Product’s Url echo $_product->getProductUrl(); //get Product’s image Url …

Continue reading »

May 16

Mysql Function

Mysql Function Mysql inbuild function as follow by categories Aggregate Function AVG – Calculate Average value of given set of expression Example: select AVG(column) from tbl_name Table (prdprice) id Name Price 25 Pencil 250.00 35 Phone 1525.00 36 Pen 254.00 58 Note Book 450.00 select AVG(price) from prdprice Output AVG(price) 619.75 COUNT – Count the …

Continue reading »

May 10

Rootscope and Scope in AngularJs

$rootscope is top-level scope. An app has only one $rootscope which will be share data among all the component of app. $rootscope is consider as global for the app. if every one want to define variable as global then he/she can use $rootscope. This method is usefull when have multiple controller in app and want …

Continue reading »

Older posts «

» Newer posts