magento controller indexaction method is working only other action method not working. when i change any method name to indexaction its other action is working. it irritate me.

http://localhost/magento/test/index {.....this url is working} http://localhost/magento/test/mamethode{.....this url is not working}

when i replace both method name with each other. In that case also indexaction is only working.

class Pfay_Test_IndexController extends Mage_Core_Controller_Front_Action
   public function indexAction()
     echo 'test index';
   public function mamethodeAction()
     echo 'test mymethod';

Magento use this pattern: moduleFrontName/controller/action In your case: test/index/index & test/index/mamethode

Your URL must be: http://localhost/magento/test/index/index http://localhost/magento/test/index/mamethode

  • thank you brice its working for me. i am too new. and read tutorial i can understand that i am reading tutorial which created for low version of magento. Dec 1 '15 at 2:46

It should be moduleFrontName/controller/action in your case

http://localhost/magento/test/index will find IndexController and automatically call index action

and for another method it should be


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.