Yii 1.0 Ajax search using Radio Buttons

Would you like to trigger one ajax request While clicking on Radio button, This post will help you to get radio button ajax request.

In _search.php (form)

<div class="wide form">
<?php $form=$this->beginWidget('CActiveForm', array(
)); ?>
<div class="row">
    <?php echo $form->radioButtonList(
                        'success'=>"$('.search-form form').submit()",
<?php $this->endWidget(); ?>
In Model.php

public function searchfiles()
    // Warning: Please modify the following code to remove attributes that
    // should not be searched.
    $criteria=new CDbCriteria;
    }else if($this->status==2)
        $criteria->condition="" ;      
    return new CActiveDataProvider(
                $this, array('criteria'=>$criteria)