Clientside Validation Not Submitting Form After Validation

Hi, i am implementing clientside form validation. But the problem is it is not submitting form after validation. It works fine if any error occurs but if there is no error in form validation then it does not submit form. please guide me where i am wrong

<?php $form=$this->beginWidget('CActiveForm', array(






                        'afterValidate'=>"js:function(form, data, hasError) {


                	if(hasError == true){						

			     if( $('.result').is(':hidden') )


			         return false;




                             return true;





is there anyone on YII forum who can help me??

Please help me, i am unable to understand what is the problem here. Just give me some hint ???

What i am trying to do is, i am validating form via ajax and if any error occurs then i will show error in a popup and apply error class on text fields. after successful validation , i am hiding the error popup and applying success class on textfields.

Everything is working fine but form is not being sent. please help me what is wrong in this code or suggest me a better solution to do this.

Try disabling ajax validation and see if a valid form will submit.



Please see it…