There is a pages controller, ActionIndex renders a page with a CListView widget
Controller Action:
public function actionIndex() { model=new Pages(); $this->render('index',array( 'pages'=>$model, )); }
Index view:
$this->widget('zii.widgets.CListView', array( 'dataProvider'=>$dataProvider, 'viewData' => array( 'switch' => true ), 'enableHistory'=>true, //включаем History back 'id'=>'pages_list', 'itemView'=>'_view', 'template'=>'{pager}<br />{items}<br />{pager}', ));
Now the actual question:
In the ListView paginator, the links look like this:
http: // localhost / pages / index / Pages_page / 1 /
http: // localhost / pages / index / Pages_page / 2 /
http: // localhost / pages / index / Pages_page / 3 /
But in the address bar the link is substituted somehow - not at all correct. Namely:
http: // localhost / pages /? / pages / index / Pages_page / 3 / =
And of course, the page does not turn over.
And if you re-go to any other page, the link will be in the form:
As far as I understand, it is necessary to pick in the direction of setting routes in URLManager. just do not quite understand what it is.