pleonovich/log
Composer 安装命令:
composer require pleonovich/log
包简介
Simple way to write log information into txt file from PHP.
README 文档
README
Simple way to write log information into txt file from PHP
Key features
- easy way to write variable information into a file
- Supports diferent kinds of information, such as: string, integer, array, boolean, null
Some examples
setPath
Setting path to log files folder.
// Description: void setPath ( string $path ) // example: LOG::setPath('Here path to log folder');
clear
Clear current log file.
// Description: void clear () // example: LOG::clear();
write
// Description: void write ( string|array|boolean|int|null $text [, string $title = null [, string $filename = null ]] ) // example: LOG::write('Here is your log information','Log title', 'test'); // result in file - 25.06.2017.test.log.txt // [2017.06.25][06:50:30][Log title] string(28) "Here is your log information"
writeError
// Description: void writeError ( string $text [, string $title = null ] ) // example: LOG::writeError('Here is your error log information','Error log title'); // result in file - 25.06.2017.error.log.txt // [2017.06.25][07:22:01][Error log title] string(34) "Here is your error log information"
writeException
// Description: void writeException ( Exception $e [, string $title = null ] ) // example: LOG::writeException('Here is exception object','Exception information');
border
// Description: void border ( [ string $title = 'BORDER' ] ) // example: LOG::border('Border title'); // result in file - 25.06.2017.log.txt //////////Border title////////////////////////////////////////////////////////////////////////////////
统计信息
- 总下载量: 26
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 2
- 推荐数: 0
其他信息
- 授权协议: Apache-2.0
- 更新时间: 2018-11-10