Difference between #1 and #5 of
How to log context information to logger (session id, user, ...)

Changes

Title unchanged

How to log context information to logger (session id, user, ...)

Category unchanged

Tutorials

Yii version unchanged

Tags changed

Logging

Content changed

Logging context information (session, user, ...) to the logfile can be of great help tracking down problems with specific users. *This will be available inrequires Yii 1.0.6.*

**config/main.php**
[...]
```php
<?php
return array(
 
    // ... 
 
    'preload'=>array('log', 'session'),
 
 
// ...
'components'=>array(
// ...
[...]
```

You could also extend
[CLogFilter] to do your own log message decoration.
 
 
### Links
 
 
[Russian Version](http://dbhelp.ru/how-to-log-context-information-to-logger/page/)
2 0
5 followers
Viewed: 25 207 times
Version: 1.1
Category: Tutorials
Tags: Logging
Written by: olafure
Last updated by: ajsharma
Created on: Jun 5, 2009
Last updated: 12 years ago
Update Article

Revisions

View all history