What is the quickest way to render the attributes of a Mage_Eav_Model_Entity_Abstract in Mage_Adminhtml_Block_Widget_Form?


Thanks to Marius's advice I solved my problem in this way.

In _prepareForm() of class that extends Mage_Adminhtml_Block_Widget_Form I do this operation:

protected function _prepareForm() {

    $form = new Varien_Data_Form();
    $fieldset = $form->addFieldset('dataModelform',
            'legend'=>Mage::helper('namespace_module')->__('Name of Fieldset'),

    $attributes = Mage::getResourceModel('eav/entity_attribute_collection')
    foreach ($attributes as $attribute) {
    $this->_setFieldset($attributes, $fieldset, array());

    $formValues = $setting->getData();
|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.