Log Files

Hi All

Quick question.

I do not really understand the Yii logs

Want I what to do is have a different log file for each action.


controller product

action save

would log in the file productSaveLog.log

Controller product

action update

Would log in the file productUpdateLog.log

Controller client

action delete

would log in the file clientDeleteLog.log

Database sqlstatments

would log into ModelNameLog.log

etc etc.

each month a new log file would start.

Any ideas how I would do this.

I do not want to put these logs in the database.

But I would like to know how to log into the database too for when I need too.


Write your own LogRoute class and use it in your configuration.

I found the Real Time Logging wiki where you can get an idea how to customize a logger.