Answer the question
In order to leave comments, you need to log in
How to properly load scripts through renderPartial in Yii?
There is a page to which the grid is rendered from another action. Scripts are loaded via a synchronous request, to which chrome throws a message to the console
Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user's experience. For more help, check xhr.spec.whatwg.org .
$cs = Yii::app()->clientScript;
$cs->scriptMap['jquery.js'] = false;
$cs->scriptMap['jquery.ba-bbq.js'] = false;
$this->renderPartial('listinggrid',array(
'model'=>$model,
), false, true)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question