PHP Classes

error logi: Log error messages to file or send by email

Recommend this page to a friend!
  Info   Example   Screenshots   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 152 All time: 9,063 This week: 571Up
Version License PHP version Categories
error-logi 3MIT/X Consortium ...3.0Logging
Description 

Author

This class can Log error messages to file or send by email.

It can send a given error message to a log file or to a given email address appending information of the date, user and server IP address and host name, user agent and user name.

The class can also log information for an user with a given id.

Class allows you to save the log file error and send them to the e-mail, The choice depends only on us, you can use both at once and save to a file and send an e-mail.
The class must specify the path to the file and assign e-mail address where you will send Our logs with errors
Themselves we determine what we want to put there, and the class appends data Such as ip, host, server, and a few others see for yourself.

Picture of adam berger
  Performance   Level  
Name: adam berger <contact>
Classes: 23 packages by
Country: Poland Poland
Age: ???
All time rank: 74521 in Poland Poland
Week rank: 170 Up1 in Poland Poland Up
Innovation award
Innovation award
Nominee: 8x

Winner: 2x

Example

<?php
 
include("error-logi.class.php");

  
$logi = new error_logi($_SERVER);
  
  
$mesage='B&#322;&#261;d log przypisujemy np. b&#322;&#261;d pdo lub mysql albo b&#322;&#261;d logowania';
     
$user='Adam ';
     
$html=true;
  
  
## ustawiamy kiedy zapisujey logi uzytkownika ##
     
$logi->user_logi_save($mesage,$user);
     
$logi->user_logi_email($mesage, $user, $html);

  
## ustawiamy kiedy zapisujey logi globalne ##
      
$logi->global_logi_save($mesage);
      
$logi->global_logi_email($mesage, $html);


Screenshots (2)  
  • error-log
  • error-log-html
  Files folder image Files (4)  
File Role Description
Accessible without login Plain text file example.php Example example
Plain text file phperror-logi.class.php Class error-logi.class

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:152
This week:0
All time:9,063
This week:571Up