summaryrefslogblamecommitdiffstats
path: root/apis/clientlog.inc.php
blob: b68e4632e57a41e9c6dfbc6509ba30cda2fd58da (plain) (tree)
1
2
3
4
5
6
7
8
9
10

     
  


                                                                                   

   

                                                   
 
                                           


                                                         
        


                                                     
 
<?php

/*
 * For compatibility with old slx-admin, where apis were not connected to a module.
 * This is clientlog, which belonged to module syslog really, plus messy hacked in
 * hook for machine+user statistics.
 */

if (empty($_POST['type'])) die('Missing options.');
$type = mb_strtolower($_POST['type']);

if ($type{0} === '~' || $type{0} === '.') {
	if (Module::isAvailable('statistics')) {
		require 'modules/statistics/api.inc.php';
	}
} else {
	if (Module::isAvailable('syslog')) {
		require 'modules/syslog/api.inc.php';
	}
}