Receive HTTP POST in Controller of my Magento Custom Module

廉价感情. 提交于 2019-12-05 05:48:18

问题


I'm learning to develop modules magento. I'm developing a payment module and it should receive a post (after closing the application) to change the status of the request and generate the invoice.

But I do not know how to get on my HTTP POST controller. I will make a post at http://mymagento.com/mymodule/receive.

class MyCompanyName_MyModule_StandardController extends Mage_Core_Controller_Front_Action{

    public function receiveAction() {
        //How receive my POST HERE??
    }

    // ...

}

I appreciate any help


回答1:


See Zend_Controller_Request_Http::getPost():

$this->getRequest()->getPost();
// or
$this->getRequest()->getPost('param');


来源:https://stackoverflow.com/questions/12380780/receive-http-post-in-controller-of-my-magento-custom-module

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!