X7ROOT File Manager
Current Path:
/usr/share/doc/cpanel-php81-log-1.13.3/examples
usr
/
share
/
doc
/
cpanel-php81-log-1.13.3
/
examples
/
📁
..
📄
composite.php
(305 B)
📄
console.php
(149 B)
📄
display.php
(280 B)
📄
error_log.php
(169 B)
📄
file.php
(216 B)
📄
firebug.php
(270 B)
📄
mail.php
(226 B)
📄
null.php
(133 B)
📄
observer_mail.php
(655 B)
📄
pear_error_handler.php
(620 B)
📄
php_error_handler.php
(768 B)
📄
sql.php
(220 B)
📄
sqlite.php
(489 B)
📄
syslog.php
(156 B)
📄
win.php
(208 B)
Editing: observer_mail.php
<?php require_once 'Log/observer.php'; class Log_observer_mail extends Log_observer { var $_to = ''; var $_subject = ''; var $_pattern = ''; function Log_observer_mail($priority, $conf) { /* Call the base class constructor. */ $this->Log_observer($priority); /* Configure the observer. */ $this->_to = $conf['to']; $this->_subject = $conf['subject']; $this->_pattern = $conf['pattern']; } function notify($event) { if (preg_match($this->_pattern, $event['message']) != 0) { mail($this->_to, $this->_subject, $event['message']); } } } ?>
Upload File
Create Folder