Skip to content

jrynhart/SimpleLogger

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Usage:

Instantiate logger: $logger = new SimpleLogger($pathToLogfile, $logfileName);

Constructor params: $pathToLogfile: no leading slash, include the trailing slash. Defaults to current folder

$logfileName: set the name of the log file here. Defaults to "logfile.txt"

Log function: $logger->log($text, $heeader);

$text: Text to write to the log file

$header: The header tag of the log entry. Defaults to '[DEBUG]'. Use any string or pass in a preset: 'i' for [INFO] or 'e' for [ERROR]

About

log text to log file for php

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published