Skip to content

lxpgw/logger

Repository files navigation

Logger

Build Status version Download Scrutinizer Code Quality Code Coverage Contact

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist lxpgw/logger "~1.0.0"

or add

"lxpgw/logger": "~1.0.0"

to the require section of your composer.json file.

Usage

send message directly

$pubu = new \lxpgw\logger\Pubu(['remote' => 'your pubu.im service url']);
$logger->send('Hello');

//with attachments
$pubu->send('Hello', [
    ['title' => 'This is title', 'description' => 'This is description.']
]);

with the log component

[
    'log' => [
        'targets' => [
            'class' => \lxpgw\logger\LogTarget,
            'chanel' => 'the pubu.im service url', // Config the channel you want send to.
            'exportInterval' => 1, //send per message directly
            'logVars' => [],
        ]
    ]
]

Tests

$ composer test

Change Log

Please see CHANGELOG for more information what has changed recently.

License

MIT

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages