registerScriptFile in Yii built-in widgets isn't set CClientScript::POS_*
If you load your's jquery , and set:
<?php
Yii::app()->clientScript->coreScriptPosition = CClientScript::POS_BEGIN;
Yii::app()->clientScript->scriptMap=array('jquery.js'=>false,'jquery.min.js'=>false);
?>
then ,use CListView , or CJuiWidget, or CFlexWidget, or CGridView, will get a js error : jQuery not defined.
Solution:
1. wait for upgrade.
2. or ,you can do :
copy the widget class file to views/widgets, modify registerScriptFile line , and append CClientScript::POS_BEGIN.
in you script, code like : $this->widget('application.views.widgets.CListView'......);
Page 1 of 1
registerScriptFile of Yii built-in widgets isn'tset CClientScript::POS_*
Share this topic:
Page 1 of 1

Help











