Custom Email Logger

Hi all,

I am trying to create a logger to send me mails in case of a error. By using google I found the following tutorial:

But in my case it is not working. I am getting no mail, no error that a logger is not properly configured or something simillar.

Any Ideas how to find out what the issue is?

Thanks a lot!

Maybe I’m missing something here … But why aren’t you simply using CEmailLogRoute? Also, I’d be tremendously helpful if you could show us the relevant part of your config ::)

main.php congif part for the loggers




'log'=>array(

			'class'=>'CLogRouter',

			'routes'=>array(


				// uncomment the following to show log messages on web pages

/*

				array(

					'class'=>'CWebLogRoute',

					'showInFireBug'=>true,

					//'categories'=>'system.db.CDbCommand',

				),

                */

                array(

                    'class'=>'CPhpMailerLogRoute',

                    'levels'=>'error, warning',

                    'emails'=>'mymail@me.com',

                ),


                array(

                    'class'=>'CFileLogRoute',

                    //'levels'=>'error, warning',

                ),


			),



I am using my custom logger as the default logger has no smtp config options.