Hello guys, i have a problem.
I want to retrieve a post with a specific id and retreive all your comments.
public function actionView($id)
{
$dataProvider=new CActiveDataProvider($this->loadModel($id), array(
'criteria'=>array(
'order'=>'data DESC',
'with'=>array('autore', 'comments'),
),
'pagination'=>array(
'pageSize'=>5,
),
));
$this->render('view',array(
'dataProvider'=>$dataProvider,
'id'=>$id
));
}
The problem.
I am not have idea how to use zii.widgets.CListView for show the post and the related comments with your pagination (and not pagination for post!).
Can you help me?