Prevent core scripts from being automatically published in Yii

Yii is automatically publishing core scripts (i.e. jQuery and some others) with each generated page. You may include following piece of code in your application configuration to disable this behavior:

'components' => array(
    'clientScript' => array(
        'scriptMap' => array(
            'jquery.js' => false,

Refer to Yii API manual, CClientScript::scriptMap section, for more details.

Leave a Reply