php - Cgridview generate pager bad link -


i have problem yii cgridview.. work properly, don't know when becomes error.. when checked inspect element, found pager generate bad link page link. that's why web error when click next button.

the cgridview generate bad link:

<a href="/gso/admin/usercontact/index/admin%2fusercontact%2findex//usercontact_page/2">2</a> 

it must be:

<a href="/gso/admin/usercontact/index/usercontact_page/2">2</a> 

why can happen? duplicate url , made error :(..

please me.. thanks

for me hard find out problem information gave.

but, yii allows define route resemble in pagination link. ie,

    'route'=>'yourcontroller/method' 

code come

    $dataprovider = new cactivedataprovider('controller',                     array                     (                         'pagination' => array                         (                            'pagesize' => 10,                            'route'=>'yourcontroller/method' //this custom route                          ),                       )                     );     $this->render('index', array(         'dataprovider' => $dataprovider,                 )); 

may (my guessing) have write route

   'route'=>'usercontact/index' 

check link more http://www.yiiframework.com/doc/api/1.1/cpagination#route-detail


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -