Clistview Afterajax Update

hey, im using an extension quickdlgs,

I Put that quickdlgs button inside clistview,

here is the code (clistview) i tried put afterajaxupdate, maybe that was wrong or missing something.




$this->widget('zii.widgets.CListView', array(

        'afterAjaxUpdate'=>'function(){$("#yw2-frame").dialog("open");}',

        'id'=>'listPost-grid',

        'template' =>' {summary}{items}{pager}',

        'summaryText' =>'{count} post(s)',  

	'dataProvider'=>$modelPost,

	'itemView'=>'//post/_view',

));



then i put the quickdlgs extension Button inside the _view




  EQuickDlgs::iframeButton(

                        array(

                            'controllerRoute' => '/post/reply',

                            'actionParams' => array('id'=>$data->id_post),

                            'dialogTitle' => 'Reply -'.$data->idPost->notes,

                            'dialogWidth' =>550,

                            'dialogHeight' =>250,

                            'openButtonText' => 'Reply',

                            'closeButtonText' => 'Close',

                            'closeOnAction' => true, //important to invoke the close action in the actionCreate

                            'refreshGridId' => 'listPost-grid',



The problem is, that extension cannot works/show the dialog(or popups) after Clistview perform ajaxupdate (refresh grid with ajax),

anyone, please help me :(.

Please use extensions forum and don’t double post next time.

At this forum communication is supposed to be in Russian.

You cannot create a popup dialog inside a view file part that gets reloaded with ajax because clientscripts will not run.

Follow the code i posted in the wiki to create a invisible button outside of view and then call the javascript in your _view file that sets the source and opens dialog.