Don't ajax a script tag

Do not place <script> tags in any type of view, because script tags get corrupted when used to replace an elements' innerHtml. Instead always use the code to "Yii::app()-> clientScript-> registerScript" to register scrips outside of a view.

Then this will always work



      $data = $this->renderPartial("theView", array("theInfo"=>$theInfo),true);


      $script .= "jQuery("#contentList").html("".


       CJavaScript::quote($data)       


       ."");";


       Yii::app()-> clientScript->       


            registerScript("theScript", "$script;", CClientScript::POS_HEAD);


nz