в ответ получаю
Fatal error: Cannot redeclare class YiiBase in C:\OpenServer\domains\delelop.loc\framework\YiiBase.php on line 55
C:\OpenServer\domains\delelop.loc\protected\config\console.php выглядит так
Код: Выделить всё
return array(
'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',
'name'=>'My Console Application',
'commandMap' => array(
'stat' => array(
'class' => 'ext.EStatCommand',
),
),
// preloading 'log' component
'preload'=>array('log'),
// application components
'components'=>array(
'db' => array(
'connectionString' => 'mysql:host=localhost;dbname=test_db',
'emulatePrepare' => true,
'username' => 'root',
'password' => '',
'charset' => 'utf8',
'tablePrefix' => '',
'enableParamLogging' => true,
'enableProfiling' => true,
),
),
);
Код: Выделить всё
error_reporting(E_ALL & ~E_NOTICE);
$yii='/var/www/gipostroy/data/testdevelop.ru/framework/yii.php'; // где лежит yii
$config=dirname(__FILE__).'/config/console.php'; // конфиг для консолек который выше описан
// remove the following line when in production mode
defined('YII_DEBUG') or define('YII_DEBUG',true); // включаем дебаг
require_once($yii);
Yii::createConsoleApplication($config)->run()
Код: Выделить всё
<?php
// change the following paths if necessary
$yiic='../framework/yiic.php';
$config=dirname(__FILE__).'/config/console.php';
require_once($yiic);
Код: Выделить всё
<?php
require_once(dirname(__FILE__).'/yiic.php');
Помогите кто чем может.