<?php include "header.admin.inc.php"; echo "<link rel='stylesheet' type='text/css' media='screen' href='../css/default.css' />\n"; echo "<link rel='stylesheet' type='text/css' media='print' href='../css/print.css' />\n"; echo "<script language=\"javascript\" src=\"../scripts/CalendarPopup.js\"></script>\n"; echo "<script language=\"javascript\">document.write(getCalendarStyles());</script>\n"; echo "<script language=\"javascript\">var cal = new CalendarPopup('mydiv');</script>\n"; echo "<script language=\"javascript\" src=\"../scripts/pnguin.js\"></script>\n"; echo "</head>\n"; setTimeZone(); echo "<body>\n";
<?php include_once "lib/ini.setting.php"; include_once "ini.config.php"; include_once "ini.dbstring.php"; include_once "ini.functions.php"; sec_session_start(); setTimeZone($_SESSION['sess_user_bid']); include_once "mod.select.php"; include_once "mod.attendance.php"; include_once "mod.login.php"; include_once "ctrl.attendance.php"; include_once "ctrl.checklogin.php"; // check user role and authentication checkSession($_SESSION['sess_user_role']); checkLogin("user", $_SESSION['sess_user_role']); $userid = !isset($_GET['userid']) || $_GET['userid'] == "" ? 1 : $_GET['userid']; $todaydate = explode("-", date("Y-n-j")); $currenttime = date("H:i:s"); $currentdate = date("Y-n-j"); ?> <html lang="en"> <head> <meta charset="utf-8"> <title>Kinntai system</title> <link href="<?php echo CSS; ?> /import.css" rel="stylesheet" type="text/css"/> <link href="<?php echo CSS;
<?php include "inc/config.php"; include "inc/auth.php"; include "inc/functions.php"; $title = "Date/Time"; include "inc/header.php"; //Save the date/time settings if the SaveDateTime if (isset($_POST['SaveDateTime'])) { if (isset($_POST['timezone'])) { $tz = $_POST['timezone']; setTimeZone($tz); } if (isset($_POST['timeserver'])) { $ts = $_POST['timeserver']; setTimeServer($ts); } echo "<div class=\"successMessage\">Configuration saved.</div>"; } ?> <h2>Date/Time</h2> <div id="form-wrapper"> <div id="form-inside"> <form action="dateTime.php" method="post" name="DateTimeSettings" id="DateTimeSettings"> <input type="hidden" name="userAction" value="DateTime"> <span class="label">Current Time</span>
function setDefaultSettings() { startSession(); # Start session. setTimeZone(); # Load Settings getFirePHPObject()->info("FirePHP Object created"); # Fire PHP - Blue badge will come with this info. }
include_once "mod.attendance.php"; include_once "mod.select.php"; include_once "mod.admin.php"; include_once "mod.group.php"; include_once "ctrl.attendance.php"; include_once "ctrl.checklogin.php"; include_once "ctrl.admin.php"; include_once "ctrl.group.php"; if (isset($_GET['uid']) && isset($_GET['cdate']) && $_GET['uid'] != "" && $_GET['cdate'] != "") { $d = explode("-", $_GET['cdate']); $userid = $_GET['uid']; // ** get user information $user = getUserProfileById($userid, $db); $wtime = getGroupTime($userid, $db); // ** set current timezone according to user type setTimeZone($user[0]['user_eid']); // ** set intime and outtime for this user's group $WORKINTIME = $wtime[0]['group_intime']; $WORKOUTTIME = $wtime[0]['group_outtime']; $getCurrentMonth = getCurrentMonth($d, $userid, $db); $late = getLateCheckIn($userid, $WORKINTIME, $d, $db); $earlyleave = getEarlyCheckOut($userid, $WORKOUTTIME, $d, $db); $absent = getAbsent($userid, $d, $db); } ?> <html lang="en"> <head> <meta charset="utf-8"> <title>Kinntai system</title> <link href="<?php echo CSS;
function plugin_timezones_postinit() { if (isset($_SESSION['glpitimezone'])) { setTimeZone($_SESSION['glpitimezone']); } }
<?php define('GLPI_ROOT', '../../..'); include GLPI_ROOT . "/inc/includes.php"; $pref = new PluginTimezonesUser(); if (isset($_POST["update"])) { if ($pref->update($_POST) && $_POST['users_id'] == Session::getLoginUserID()) { setTimeZone($_POST['timezone']); // to reset timezone for current session } Html::back(); } Html::redirect($CFG_GLPI["root_doc"] . "/front/preference.php?forcetab=" . urlencode('PluginTimezonesUser$1'));