(Yaf >=1.0.0)
Yaf_Request_Abstract::getParams — Retrieve all parameters
Retrieves all parameters from the request.
This function has no parameters.
An array of all parameters, or null if none are set.
Example #1 Yaf_Request_Abstract::getParams() example
<?php
class ProductController extends Yaf_Controller_Abstract
{
public function viewAction()
{
// Assuming the request is /product/view/id/17/sort/price
var_dump($this->getRequest()->getParams());
}
}
?>The above example will output something similar to:
array(2) {
["id"]=>
string(2) "17"
["sort"]=>
string(5) "price"
}