Hi I need help in this line of code, I already searched in the docs I found $this->request->params['pass'][0]
but I can't understand what's it's use
What does $this->request->params['pass'][0]
mean?
Can anyone please help me into this?
In CakePHP 2.0 this appears to have changed. According to the documentation you can access $this->request->query or $this->request['url'] .
You can retrieve post data as Array. $post_data= $this->request->data; You can retrieve post data for particular key.
http://book.cakephp.org/2.0/en/controllers/request-response.html
$this->request->params['pass']
represents the passed parameters within a url
Example: your request url localhost/calendars/view/recent/mark
Both recent
and mark
are passed arguments to CalendarsController::view()
$this->request->params['pass']
is an array valued array ([0]=>recent [1]=>mark)
So, in the above example
$this->request->params['pass'][0] = "recent"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With