Basic implementation of a CLogRoute
that routes to (ChromeLogger)[https://github.com/ccampbell/chromelogger].
Grab a copy of (ChromePhp.php)[https://github.com/ccampbell/chromephp] and drop into {application root}/vendor/chromephp
along with ChromePhpLogRoute.php
below.
Configure as follows:
'log'=>array(
'class' => 'CLogRouter',
'routes' => array(
// ...
'chrome' => array(
'class' => 'application.vendor.chromephp.ChromePhpLogRoute',
'levels' => 'trace, error, warning, info',
'enabled' => true,
'categories' => 'application.*, system.db.CDbCommand',
),
),
),
'db' => array(
'enableProfiling' => true,
'enableParamLogging' => true,
// ...
),
Install and enable ChromeLogger, and you should see DB queries etc. on your Chrome console, even during AJAX requests...