I have been stuck for few days on ajax pagination..
in my controller
, I have
$dataProviderRegSum = new CSqlDataProvider($rawData, array(
'keyField' => 'FamilyId',
'totalItemCount' => $count,
'pagination'=>array('pageSize'=>20)
));
here $rawdata is the result of query...
and in my view
,I have
$this->widget('zii.widgets.grid.CGridView', array(
'id'=>'family-record-grid',
'dataProvider'=>$dataProviderRegSum,
'enableSorting' => true,
//'cssFile' => $cssfile,
'itemsCssClass'=>'tabchin',
'columns'=>()
)
);
this is my grid view ,where I wanna display data with pagination
..
my problem is that,while pagination ,total page is loading ...
but i want pagination with ajax in yii
,without loading fullpage..
how to achieve it,please anybody help.....thanks for reading my question....
Please try this,
$this->widget('zii.widgets.grid.CGridView', array(
'id'=>'family-record-grid',
'dataProvider'=>$dataProviderRegSum,
'enableSorting' => true,
//'cssFile' => $cssfile,
'ajaxUpdate' => true,
'itemsCssClass'=>'tabchin',
'columns'=>()
));
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.