Skip to main content

Posts

Showing posts from January 6, 2010

Magento - how to add new attributes

To add customiged fields for shop customer.. First We can make a module to extend the functionality of the customer module already in magento. First adding the module xml file to the app/etc/modules/ directory. You need to decide on a module name. In this example we will use the Sarvottom scope, and call the module 'NewCustomer'. Therefore we need to create a file named Sarvottom_NewCustomer.xml and add the following content: <code> <config> <modules> <Sarvottom_NewCustomer> <active>true</active> <codePool>local</codePool> </Sarvottom_NewCustomer> </modules> </config> </code> Second to add the above file means that Magento is now aware of a new custom module been added as local module. Now, we need to create the module itself, which must be located in the app/code/local/Sarvottom/NewCustomer directory. Inside this directory, create an etc directory...