I use bootstrap with Yii an load Jquery from theme
$cs->registerScriptFile($baseUrl.'/vendor/jquery/jquery.js', CClientScript::POS_END);
It loads jQuery v1.11.2. But my Yi framework yii-1.1.14.f0fee9 uses jQuery v1.8.3
Now when I set ‘enableAjaxValidation’=>true or ‘enableClientValidation’=>true
on ‘CActiveForm’ I got the following error:
Uncaught TypeError: jQuery(...).yiiactiveform is not a function
I found that this error shows me jQuery gets loaded a second time and overrides the original jQuery object which had the Yii plugins attached. Now, when I use original JQuery from Yii, I get an error from bootstrap components. What is he solution?
I try to use the new JQuery for only my ‘CActiveForm’ widget.
Something like:
'widgetFactory'=>array(
'widgets'=>array(
'CJui<CActiveForm>'=>array(
'scriptUrl'=>'jquery',
'themeUrl'=>'jquery.ui',
),
),
),
in config/main.php
But it does not work.