cakePHP paginate with post data without sessions, serialization or post to get
Posted
by openprojdevel
on Stack Overflow
See other posts from Stack Overflow
or by openprojdevel
Published on 2010-05-28T07:07:17Z
Indexed on
2010/05/28
7:12 UTC
Read the original article
Hit count: 515
I have created a small search and filter form method post in controller/index, which posts to it self the conditions and fields to paginate ( $this->paginate($conditions) )
However that is good for the first page, the subsequent pages the filer conditions are lost. pagination passArgs supports get variables well.
Is there an un complex way to pass the post conditions to the other paginated pages?
The method I have looked at is pass the $conditions in session , which isnt without complexity of assigning session and unset the session on submitting the form again (more refinements to the filter criteria by the user ) The other method is passing the $conditions as serialized string url_encode as an get parameter.
Is there an good cake way to do this more like passArgs, sessions and url encode do not look like cake style.
Thanks
© Stack Overflow or respective owner