3

I have created a custom module in magento 1.9.2 named " question & answer "

I have the phtml file placed in directory magento/app/design/frontend/rwd/template/question.phtml

enter image description here

now, the form action should validate the form and I have the controller placed in magento/app/code/local/Mynamespace/Questions/controllers I have the below index controller

enter image description here

and I want to call the questionAction .Bit confused as I am a neophyte with this technology. Any help to this will be appreciated much.

Community
  • 1
  • 1
Jijo Nair
  • 828
  • 2
  • 11
  • 30

1 Answers1

2

I think what you can do is in your phtml file, write this in your form action :

<form action = "<?php echo Mage::getUrl('yourRouterName/index/question'); ?>">

And this router name you would have written in your config.xml, while defining the package(or module).

Abhishek Dhanraj Shahdeo
  • 1,356
  • 2
  • 14
  • 35