سؤال

In Yii 1.x you have the CWebLogRoute class to log all your queries and stuff in your browser. Is this option already available for Yii 2.0? I only see the FileTarget, DbTarget and EmailTarget classes in the framework.

هل كانت مفيدة؟

المحلول 2

It's called debugger now in Yii 2.0. To enable it, put this in your configuration:

'preload' => ['debug'],
'modules' => [
    'debug' => 'yii\debug\Module'
],

نصائح أخرى

The correct answer:

return [
    'bootstrap' => ['debug'],
    'modules' => [
        'debug' => 'yii\debug\Module',
        // ...
    ],
];
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top