I dont get it…Debug and Production-Mode in Yii 2 Advanced Template:
I read, that i have to delete the following code for change to Production mode.
if (!YII_ENV_TEST) {
// configuration adjustments for 'dev' environment
$config['bootstrap'][] = 'debug';
$config['modules']['debug'] = [
'class' => 'yii\debug\Module',
];
$config['bootstrap'][] = 'gii';
$config['modules']['gii'] = [
'class' => 'yii\gii\Module',
'allowedIPs' => ['*'],
];
}
but are the following Lines??
I red also that i have to change true to false for Production Mode… but when i change to true… Nothing happens still get the debug bar
defined('YII_DEBUG') or define('YII_DEBUG', true);
defined('YII_ENV') or define('YII_ENV', 'dev');
now my question is, when i have to remove the code in de config file… for what is the code in the index.php??
thank you