Documentation: Log system
From UniLang Wiki
The log system enables UniLang pages to write to the main system log. It consists out of a backend /main/log.php and a frontend log-viewer /main/logview.php.
[edit]
Writing to the main log
Obviously you need to first include the backend:
<? require($maindir . "/log.php"); ?>
Then you can call the function writelog, which is defined as followed:
function writelog($message, $class = "information", $source = "")
- $message is the actual message that goes into the log. It may contain HTML code.
- $class is a class this message belongs to, it can be either "information", "error","contribution" or "warning". Messages will be colored differently and have different priorities in the Log Viewer according to this class. So choose wisely.
- $source Is the source script, if left empty this defaults to the name $countname also used by statistics system.
