in the _view.php, i have the following codes
<?php $this->widget('zii.widgets.CListView', array(
//'id' => 'answer-list', // i cannot specify an id for this clistview, because there are actually many clistviews in this page and they are generated automatically(each _view has several clistviews)
'dataProvider'=>new CArrayDataProvider($data->answers, array(
'keyField'=>'id',
'pagination' => array(
'pageSize' => 5,
),
)),
'itemView' => '/answer/_view',
));?>
in the index.php page
$.fn.yiiListView.update(
// this is the id of the CListView
'ajaxListView',
{data: ajaxRequest}
)
the first parameter is the id of the clistview. here comes the question. because I cannot specify an id for each clistview, so there is no id, so how can I tell this function which clistview to update? Can I use something like jquery selectors? (e.g. $(‘a-class-name’))