Ajax Problem On Submit In Search-Form


I have problem with Ajax (Not posting data when form submits see screenshot),

task is {

showing the selected field of search on Success, like what user selected!


Yii::app()->clientScript->registerScript(‘search’, "

$(’.search-form form’).submit(function(){

$.fn.yiiGridView.update('violence-mentioned-grid', {

	data: $(this).serialize()




 [b][i] jQuery.ajax({

        'success': function(data) {




        'type': 'POST',

        'data': $(this).serialize(),

        'url': '".$this->createUrl('/violencementioned/contentText')."',



return false;



<div id="Description"></div>

Please help me in this or other solution for above problem , if you can !


Have you any output in contentText? i.e. Yes or list of items etc?

moreover, try firefox’s console for js and debug the call using it.

thanks for reply:

in contentText i have message i.e echo "Yes";

i have checked it in firebug (consol)