I am trying to implement pagination with custom url, when i try to paginate to the next page i am getting the following error.
The requested address '/adminuser/userlist/page:2' was not found on this server.
Here adminuser is the name of the admin user and userlist is the method to get all the users under this adminuser.
The url will look like this http://domain.com/adminuser/userlist
Here is my code
In view:
<?php $this->paginator->options(array('url' =>
array('path'=>$this->params['path']))); ?>
<div class="pagination">
<ul>
<li class="prevnext disablelink">
<?php echo str_replace('/users/','',$this->paginator->prev('« Prev'));?>
<li>
<?php echo str_replace('/users/','',$this->paginator->numbers());?>
</li>
<li class="prevnext">
<?php echo str_replace('/users/','',$this->paginator->next('Next »'));?>
</ul>
</div>
routes.php
Router::connect('/:sluguser/:action', array('controller' => 'users', 'action' => 'userlist'),array('pass' => array('sluguser')));