mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-17 12:09:28 +00:00
Logging von Suchanfragen zur Verbesserung der UX
This commit is contained in:
@@ -39,6 +39,7 @@ require_once('../../../include/person.class.php');
|
||||
require_once('../../../include/mitarbeiter.class.php');
|
||||
require_once('../../../include/kontakt.class.php');
|
||||
require_once('../../../include/bisverwendung.class.php');
|
||||
require_once('../../../include/webservicelog.class.php');
|
||||
|
||||
$uid = get_uid();
|
||||
$db = new basis_db();
|
||||
@@ -90,6 +91,20 @@ while ($array_key = array_search("", $searchItems))
|
||||
if(implode(',', $searchItems) == '')
|
||||
exit;
|
||||
|
||||
// Legt einen Logeintrag für die Suchstatistik an
|
||||
if (defined('LOG_CONTENT') && LOG_CONTENT==true)
|
||||
{
|
||||
$log = new webservicelog();
|
||||
|
||||
$log->webservicetyp_kurzbz = 'content';
|
||||
$log->request_id = '';
|
||||
$log->beschreibung = 'suche';
|
||||
$log->request_data = implode(';',$searchItems);
|
||||
$log->execute_user = $uid;
|
||||
|
||||
$log->save(true);
|
||||
}
|
||||
|
||||
//Easter Egg
|
||||
$easteregg = array ('antwort','leben','universum','rest','answer','universe','life','everything');
|
||||
$easteregg_intersect = array_intersect(array_map('strtolower',$searchItems), $easteregg);
|
||||
|
||||
Reference in New Issue
Block a user