exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('show_gabBreaks','0')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('show_RecordAgain','1')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('show_TrackingNr','1')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('date_format_0','%d.%m.%Y')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('date_format_1','%d.%m.')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('date_format_2','%d.%m.%Y')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('language','{$kga['language']}')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('roundPrecision','0')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('decimalSeparator',',')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('durationWithSeconds','0')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('defaultTimezone','" . mysql_real_escape_string($_REQUEST['timezone']) . "')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('exactSums','0')"); exec_query("INSERT INTO `{$p}var` (`var`,`value`) VALUES('defaultVat','0')"); // init timespace for admin user to current month $mon = date("n"); $day = date("j"); $Y = date("Y"); save_timespace(mktime(0, 0, 0, $mon, 1, $Y), mktime(23, 59, 59, $mon, lastday($month = $mon, $year = $Y), $Y), $randomAdminID); if ($errors) { require_once '../libraries/smarty/Smarty.class.php'; $tpl = new Smarty(); $tpl->template_dir = '../templates/'; $tpl->compile_dir = '../compile/'; $tpl->assign('headline', $kga['lang']['errors'][1]['hdl']); $tpl->assign('message', $kga['lang']['errors'][1]['txt']); $tpl->display('misc/error.tpl'); logfile("-- showing install error --------------------------"); } else { logfile("-- installation finished without error ------------"); header("Location: ../index.php"); }
case 'setTimespace': if (!isset($kga['usr'])) { die; } $timespace = explode('|', $axValue); $timespace_in = explode('-', $timespace[0]); $timespace_in = (int) mktime(0, 0, 0, $timespace_in[0], $timespace_in[1], $timespace_in[2]); if ($timespace_in < 950000000) { $timespace_in = $in; } $timespace_out = explode('-', $timespace[1]); $timespace_out = (int) mktime(23, 59, 59, $timespace_out[0], $timespace_out[1], $timespace_out[2]); if ($timespace_out < 950000000) { $timespace_out = $out; } save_timespace($timespace_in, $timespace_out, $kga['usr']['usr_ID']); break; /** * The user started the recording of an event via the buzzer. If this method * is called while another recording is running the first one will be stopped. */ /** * The user started the recording of an event via the buzzer. If this method * is called while another recording is running the first one will be stopped. */ case 'startRecord': if (isset($kga['customer'])) { die; } if (get_rec_state($kga['usr']['usr_ID'])) { stopRecorder();