Magento - Product Attribute Values - Set Programmatically

Posted by Damodar Bashyal on March 21, 2012

 

I needed to import manufacturers list from oscommerce to magento and this is how i did it, not sure if there is an easy way to do this. Let me know if you know better way to do it.

Lets create a file (manufacturer.php) on the root of the magento installation path, and add below code and run the file. Code is self explanatory I guess :)

More»

How to enable Address Information on Magento Customer Registration Page?

Posted by Damodar Bashyal on March 12, 2012

 

Step 1: app\etc\modules\Technooze_All.xml

<?xml version="1.0"?>
<config>
    <modules>
        <Technooze_Customer>
            <active>true</active>
            <codePool>community</codePool>
        </Technooze_Customer>
    </modules>
</config>

More»

How to get Current Category in Magento?

Posted by Damodar Bashyal on March 07, 2012

 

In Magento, If you are on category page than it's easy to get current category.

$_current_category=$this->getCurrentCategory();

or,

$_current_category = Mage::registry('current_category');

I needed Current Category on product info page and on the footer.phtml files. Because I had custom background set for each Category. So, Below code helped me to find the Current Category in my Magento's phtml file.

More»