You might have seen website where the product images changes when you move mouse on it. In this tutorial i’ll show you how to do it with Magento. You need to create a small module to achieve this. We will…
Get Product Image based on its Position – Magento
Blog Archives
Magento – Install and Upgrade Database script
I struggled a lot to find a method to install a simple database script in Magento for creating a table or upgrading field or column. In the end I thought why not write one for reference. This post is mainly…
Passing values and parameters to template file using XML and ShortCode from Magento Admin
At times there is a need to pass some parameters to template file in Magento. Some of the conditions are as follow: 1) Category Id is needed to be passed to display all the products of that particular category 2)…
Reset Order id after clearing dummy Orders in Magento
After developing a website, Developers delete all the dummy order placed using either a SQL script or using one of the free extension available on Magento Connect. After deleting orders, the Order Id still continues to be in the previous…
Display special priced products on your Magento homepage
Step 1: Open your homepage CMS page and click on the content tab. Paste the following: {{block type=”catalog/product” name=”home.new” alias=”product” template=”catalog/product/special.phtml”}} Step 2: First of all this is the code were that we’re going to be using to do…
How to install/setup language pack in Magento
Are you confused with installing language pack in Magento? Don’t be its too easy 😉 In this post we will go through Installing language pack in Magento Step 1 : Select the language you want to set on your website.…
Display magento products by category ID
<?php $categoryIds = array(18);//category id $collection = Mage::getModel(‘catalog/product’) ->getCollection() ->joinField(‘category_id’, ‘catalog/category_product’, ‘category_id’, ‘product_id = entity_id’, null, ‘left’) ->addAttributeToSelect(‘*’) ->addAttributeToFilter(‘category_id’, array(‘in’ => $categoryIds)) $_collectionSize = $collection->count() ?> Get detail of products <ul> <?php $i=0; foreach ($collection as $_product):Â ?> <?php $i++;?>…
Display Products in shopping cart in a drop down format in Magento
You might have seen the cart summary drop down in many websites as shown in the image below. Making such a drop down is pretty easy using Magento. You just need to know little bit of jquery for it. Follow…
Registration Mobile number validation In Magento
Some time in account registration we need validate mobile no, for that use this code <input type=”text” name=”telephone” id=”telephone” value=”<?php echo $this->htmlEscape($this->getFormData()->getTelephone()) ?>” title=”<?php echo $this->__(‘Telephone’) ?>” class=”input-text validate-mobileno” /> Replace script  <script type=”text/javascript”> //<![CDATA[  var dataForm = new VarienForm(‘form-validate’,…
Check if product is set as New in Magento.
Magento has a great functionality to mark product as New within a range of date. At times we want the new product to be highlighted with the TAG say NEW as shown in the figure below. To make such a…