Skip to main content Help Control Panel

Aubagne HipHop

Tout le Hip Hop d'Aubagne et des alentours

Home «   Server software «  

Documentation: agents/logger.php

class Logger - Log strings

Use functions of this library in your code depending on the expected effect:

This script is a reference file of this system.

Licence: GNU Lesser General Public License

Auteurs:

debug() - Remember a string during software debug

function debug($value='', $label=NULL)

This script appends information to agents/debug.txt, or echo a string to the standard output.

get_tail() - Get the latest events

function get_tail($count=20, $variant='all')

notify() - Notify an event

function notify($script, $label, $description='')

This script calls Logger::remember() to save the event locally, then attempts to send an e-mail message if possible.

The description is truncated after 4 kbytes.

remember() - Remember an event

function remember($script, $label, $description='', $store='log')

This script adds a line to agents/log.txt.

It the selected store is 'log', the function also submits a message to syslog(), to enable distributed logging.

Each line of the log store is made of fields separated by tabulations:

Each line of the debug store is made of fields separated by tabulations:

to_string() - Make a string out of something

function &to_string($value='')

Tools
Browse the source of this script
Server software