1

I tried rewrite catalog_product_review controller in admin but failed. I'm not aware of problem. Does anyone know problem maybe help me?

Thanks

config.xml:

<config>
    <modules>
        <Hn_Mymodule>
            <version>0.1.0</version>
        </Hn_Mymodule>
    </modules>
     <admin>
        <routers>
            <adminhtml>
                <args>
                    <modules>
                        <mymodule before='Mage_Adminhtml'>Hn_Mymodule</mymodule>
                    </modules>
                </args>
            </adminhtml>
        </routers>
    </admin>
</config>

Hn/Mymodule/controllers/Adminhtml/Catalog/Product/ReviewController.php

require_once 'Mage/Adminhtml/controllers/Catalog/Product/ReviewController.php';

class Hn_Mymodule_Adminhtml_Catalog_Product_ReviewController extends Mage_Adminhtml_Catalog_Product_ReviewController{

    public function indexAction()
    {
        echo "test index";
    }

    public function saveAction()
    {
        echo "test save";
    }

}
2

The problem is with this line

<mymodule before='Mage_Adminhtml'>Hn_Mymodule</mymodule>

It should be

<mymodule before='Mage_Adminhtml'>Hn_Mymodule_Adminhtml</mymodule>

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.