1

I've created this CActiveDataProvider:

  $dataProvider=new CActiveDataProvider('Post',array(
    'criteria'=>array(
      'condition'=>$condition,
      'params'=>$params,
    ),
    'pagination'=>array(
      'pageSize'=>2,
    ),
  ));

but ... How can I define current page and load records 3,4 instead of 1,2? How can I get a precise page?

sensorario
  • 20,262
  • 30
  • 97
  • 159

1 Answers1

7

Set the zero-based currentPage attribute of the pagination

...
'pagination'=>array(
  'pageSize'=>2,
  'currentPage'=>1,
),
...
topher
  • 14,790
  • 7
  • 54
  • 70