hi,
I read this tutorial,
http://www.yiiframework.com/wiki/72/cjuidialog-and-ajaxsubmitbutton
it is a great one,
however
it submits the form 2 times, and sometimes 3 times.
the author has added a comment, which does not seem to solve the problem.
/*This will fix multiple ajax submittion problem */
/* Use the below undelegate function to destroy JQuery event.
Otherwise when you open dialog 1st time, It will do ajax submission 1 time,
if you open 2end time, It will submit 2 times etc..
You could see the ajax submission in firebug */
$this->beginWidget('zii.widgets.jui.CJuiDialog',array(
'id'=>"dmaDialog",
'options'=>array(
'closeOnEscape'=>true,
'title'=>Yii::t("dma",'CREATE DMA'),
'autoOpen'=>true,
'modal'=>'true',
'width'=>'450px',
'height'=>'auto',
'resizable' =>false,
'close'=>"js:function(e,ui){
jQuery('body').undelegate('#closeDmaDialog', 'click');
jQuery('#dmaDialog').empty();
}",
),
));
this solution does not help at all.
the tutorial is really good benefit, but this error looks like the fly in the ointment, big fly.
any suggestions?