addAttribute('customer', $middlenameAttributeCode, array( 'type' => 'varchar', 'label' => 'Middle Name/Initial', 'input' => 'text', 'required' => 0, 'sort_order' => 50, 'is_visible' => 1, 'is_system' => 0, 'position' => 50 )); $middlenameAttribute = Mage::getSingleton('eav/config') ->getAttribute('customer', $middlenameAttributeCode); $middlenameAttribute->setData('used_in_forms', array( 'customer_account_create', 'customer_account_edit', 'checkout_register', 'adminhtml_customer', 'adminhtml_checkout' )); $middlenameAttribute->save(); $installer->addAttribute('customer_address', $middlenameAttributeCode, array( 'type' => 'varchar', 'label' => 'Middle Name/Initial', 'input' => 'text', 'required' => 0, 'sort_order' => 30, 'is_visible' => 1, 'is_system' => 0, 'position' => 30 )); $middlenameAttribute = Mage::getSingleton('eav/config') ->getAttribute('customer_address', $middlenameAttributeCode); $middlenameAttribute->setData('used_in_forms', array( 'adminhtml_customer_address', 'customer_address_edit', 'customer_register_address' )); $middlenameAttribute->save();