0
votes

I Follow this tutorial (http://www.youtube.com/watch?v=xKhT1fISgAs) to add bootstrap with yii framework, But got this error

Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in E:\xampp\htdocs\yii_tuts\tt\protected\config\main.php on line 13

I follow each step in this tutorial. But in video everything fine.

Here is my code in main config file

<?php

// uncomment the following to define a path alias
// Yii::setPathOfAlias('local','path/to/local-folder');

// This is the main Web application configuration. Any writable
// CWebApplication properties can be configured here.
return array(
    'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',
    'name'=>'My Web Application',

    'aliases'=>array(
        'bootstrap' => realpath(__DIR__'/../extension/yiibooster'),
    ),

    // preloading 'log' component
    'preload'=>array('log', 'bootstrap'),
    'theme'=>'heart',
    // autoloading model and component classes
    'import'=>array(
        'application.models.*',
        'application.components.*',
    ),

Can you point the error

1

1 Answers

2
votes

You missed one .. Change your code like below:

'aliases'=>array(
    'bootstrap' => realpath(__DIR__.'/../extension/yiibooster'),
),