Alex Rivera | Logout

How can I check if request is post in Zend Framework

Asked 2010-12-19T03:35:46.817
23

I remember using something like

$this->getRequest()->isPost()

but it seems like there isn't such a function. How can I check if the request is post so I can validate the form etc

Edit
Report

1 Answer

10
   if($this->getRequest()->getMethod() == 'POST') {
       echo "You've got post!";
   }

isPost() should be there too, though, I don't know why you don't find it.

answered 2010-12-19T03:42:08.937

Your Answer