*/ class Mage_Adminhtml_Block_Sitemap_Edit extends Mage_Adminhtml_Block_Widget_Form_Container { /** * Init container */ public function __construct() { $this->_objectId = 'sitemap_id'; $this->_controller = 'sitemap'; parent::__construct(); $this->_addButton('generate', array( 'label' => Mage::helper('adminhtml')->__('Save & Generate'), 'onclick' => "$('generate').value=1; editForm.submit();", 'class' => 'add', )); } /** * Get edit form container header text * * @return string */ public function getHeaderText() { if (Mage::registry('sitemap_sitemap')->getId()) { return Mage::helper('sitemap')->__('Edit Sitemap'); } else { return Mage::helper('sitemap')->__('New Sitemap'); } } }