Ejemplo n.º 1
0
    $rows = array();
    if ($count > 1) {
        foreach ($res as $value) {
            $rows[] = $value;
        }
    }
    $parameter = 'action=photo&doing=view_photo&photo_id=7&';
    $pagebar = pagebar(get_self(), $parameter, $page_current, $page_size, $count);
    $smarty = new smarty();
    smarty_header();
    $smarty->assign('pagebar', $pagebar);
    $smarty->assign('photo', $rows);
    $smarty->display('admin_photo_list.html');
}
if ($doing == 'manage_photo') {
    check_browser();
    check_user();
    $format = "SELECT * FROM `{$db_prefix}photo`";
    $query = $db->query($format);
    $page_size = 10;
    $page_current = isset($_GET['page']) && is_numeric($_GET['page']) ? intval($_GET['page']) : 1;
    $count = $db->getCount($format);
    $res = $db->getAll($format . " LIMIT " . ($page_current - 1) * $page_size . "," . $page_size);
    $rows = array();
    if ($count > 1) {
        foreach ($res as $value) {
            $rows[] = $value;
        }
    }
    $parameter = 'action=photo&doing=manage_photo&';
    $pagebar = pagebar(get_self(), $parameter, $page_current, $page_size, $count);
Ejemplo n.º 2
0
      

      <h1>eID-LV test site</h1>
      <p>Welcome to Latvian eID test site!</p>
   
      </div>
      
             <div class="marketing">
	   <div style="text-align: center;" class="marketing">
	   
	
      <p>
      	
		<?php 
//check browser
$is_problematic_browser_error = check_browser();
if ($is_problematic_browser_error == false) {
    //if browser is ok, display users smarcard data
    //see inc/functions.php for smartcard_user array description
    $smartcard_user = get_smartcard_user();
    ?>
				<h1><?php 
    echo $smartcard_user['fullname'];
    ?>
, Your eID-LV works correctly!</h1><br><br>
				We have read this information from authentication certificate included in Your eID-LV: <br>
				Name, surname: <?php 
    echo $smartcard_user['fullname'];
    ?>
<br>
				Personal number: <?php 
Ejemplo n.º 3
0
define('DEBUG', 1);
// 发布的时候改为 0
define('APP_NAME', 'bbs');
// 应用的名称
define('APP_PATH', '../../');
// 应用的路径
chdir(APP_PATH);
$conf = (include './conf/conf.php');
include './xiunophp/xiunophp.php';
include './xiunophp/form.func.php';
include './model.inc.php';
$user = user_token_get('', 'bbs');
$user['gid'] != 1 and message(-1, '需要管理员权限才能设置。');
// 检测浏览器
$browser = get__browser();
check_browser($browser);
$runtime = runtime_init();
if ($method == 'GET') {
    $sphinx = kv_get('sphinx');
    !isset($sphinx['enable']) && ($sphinx['enable'] = 0);
    !isset($sphinx['sphinx_host']) && ($sphinx['sphinx_host'] = '');
    !isset($sphinx['sphinx_port']) && ($sphinx['sphinx_port'] = '');
    !isset($sphinx['sphinx_datasrc']) && ($sphinx['sphinx_datasrc'] = '');
    !isset($sphinx['sphinx_deltasrc']) && ($sphinx['sphinx_deltasrc'] = '');
    $input['enable'] = form_radio_yes_no('enable', $sphinx['enable']);
    $input['sphinx_host'] = form_text('sphinx_host', $sphinx['sphinx_host'], 300);
    $input['sphinx_port'] = form_text('sphinx_port', $sphinx['sphinx_port'], 100);
    $input['sphinx_datasrc'] = form_text('sphinx_datasrc', $sphinx['sphinx_datasrc'], 300);
    $input['sphinx_deltasrc'] = form_text('sphinx_deltasrc', $sphinx['sphinx_deltasrc'], 300);
    $header = array();
    $header['title'] = 'Sphinx 搜索服务设置';
Ejemplo n.º 4
0
    if (check_browser() == "normal") {
        echo '<body onload="javascript: clock(';
        echo date("U") * 1000;
        echo '); countdown(2010,6,10,';
        echo date("U") * 1000;
        echo ');">';
    } else {
        echo '<body>';
    }
}
?>
    <!-- Main Page Container -->
  	<div class="page-container">

        <?php 
if (check_browser() != "normal" && $_SERVER["SCRIPT_NAME"] != "/Browsers.php") {
    print "<meta http-equiv=\"Refresh\" content=\"0;URL=Browsers.php\">";
    exit;
}
?>



	<!-- modal content -->
		<div id="osx-modal-content">
			<div id="osx-modal-title">��������(�)
				<?php 
if ($_SESSION['user_name'] == $_SESSION['user_patronymic']) {
    echo $_SESSION['user_name'] . "!";
} else {
    echo $_SESSION['user_name'] . " " . $_SESSION['user_patronymic'] . " !";
Ejemplo n.º 5
0
include_once 'include/functions_calendar.php';
$get_alerts = get_parameter('get_alerts', 0);
$get_alert_popup = get_parameter('get_alert_popup', 0);
$check_alarms_popup = get_parameter('check_alarms_popup', 0);
$set_alarm_checked = get_parameter('set_alarm_checked', 0);
if ($get_alerts) {
    $check_cron = check_last_cron_execution();
    $check_emails = check_email_queue();
    $minutes_last_exec = check_last_cron_execution(true);
    $seconds_last_exec = $minutes_last_exec * 60;
    $queued_emails = check_email_queue(true);
    $update_manager_msg = get_parameter('update_manager_msg', '');
    $check_alarm_calendar = check_alarm_calendar();
    $check_directory_permissions = check_directory_permissions();
    $check_minor_release_available = db_check_minor_relase_available();
    $check_browser = check_browser();
    $alerts = '';
    if ($minutes_last_exec == '') {
        $alerts .= '<h4 style="width:100%; float: left; font-size:15px !important; font-weight: bold; margin-top:32px;">' . __('Crontask not installed. Please check documentation!') . '</h4>';
    }
    if (!$check_cron) {
        $alerts .= '<h4 style="width:100%; float: left; font-size:15px !important; font-weight: bold; margin-top:32px;">' . __('Last time Crontask was executed was ') . calendar_seconds_to_humand($seconds_last_exec) . __(' ago') . '</h4>';
    }
    if (!$check_emails) {
        $alerts .= '<h4 style="width:100%; float: left; font-size:15px !important; font-weight: bold; margin-top:32px;">' . __('Too many pending mail in mail queue: ') . $queued_emails . '. Check SMTP configuration' . '</h4>';
    }
    if ($update_manager_msg != '') {
        $update_manager_msg .= "<br><a href='index.php?sec=godmode&sec2=godmode/setup/update_manager'>" . __("Go to Update Manager") . "</a>";
        $alerts .= '<h4 style="width:100%; float: left; font-size:15px !important; font-weight: bold; margin-top:32px;">' . $update_manager_msg . '</h4>';
    }
    if ($check_alarm_calendar) {
Ejemplo n.º 6
0
 function load($ifsses, $appid)
 {
     //Avant tout on check le browser
     //exit($appid);
     if (!check_browser()) {
         $errpage = "Navigateur non supporté<br> merci de contacter le Service Informatique de l'ONAPE.";
         header("location:ff.exe");
         exit(msgbox($errpage, 0, '', 45));
     }
     global $db;
     Cookie::close_session_open();
     //Cookie::session_autoclosed();
     //Set default App if need Session or not
     // $_GET['_tsk'] est le parametre qui appel l'application demandée
     //
     $default_applic_id = $ifsses == 1 ? 'login' : $appid;
     //exit(tg('_tsk'));
     if (tg('_tsk') != '0') {
         $app_id = tg('_tsk');
         $msg = "Vous n'êtes pas autorisé(e) à accéder à cette Application , redirection vers acceuil....  ";
         if (!$db->Query("SELECT * FROM task where app='{$app_id}'")) {
             $db->Kill($db->Error());
         }
         $array = $db->RowArray();
         $appc_idc = $array['id'];
         $needsession = $array['session'];
         if ($db->RowCount() <= 0) {
             exit(msgbox($msg, 0, './', 5));
         }
         //app autorized sans session
         $array_godapp = array(1, 2, 3, 4, 5, 6, 11, 21);
         $needajax = $array['ajax'];
         if ($needajax == 1) {
             exit(msgbox($msg . 'ajax', 0, './', 5));
         }
         if ($needsession == 1 && !isset($_SESSION['userid'])) {
             exit(msgbox($msg, 0, './', 5));
         }
         if (!in_array($appc_idc, $array_godapp)) {
             $sql = "SELECT *  FROM permission_users where perm=1 and  appid=" . $appc_idc . " and userid=" . $_SESSION['userid'];
             if (!$db->Query($sql)) {
                 $db->Kill(exit($sql));
             }
             if ($db->RowCount() <= 0) {
                 exit(msgbox($msg, 0, './', 5));
             }
         }
         //************************************
         $app_rep = $array['rep'];
         $app_file = $array['file'];
         $app_active = $array['dscrip'];
         define('ACTIV_APP', $array['dscrip']);
         //si l'application demandée n'a pas besoin de session retour à l'index
         if ($array['session'] == 0 && $ifsses == 2) {
             header('location:./');
         }
         //verif si application exist
         if ($app_rep != '') {
             $this->application = (require_once CONTROLLER_REP . SLASH . $app_rep . SLASH . $app_file . '_c.php');
         } else {
             header('location:./');
         }
     } else {
         if (!$db->Query("SELECT * FROM task where app='" . $default_applic_id . "'")) {
             $db->Kill('Error1');
         }
         $array = $db->RowArray();
         $app_rep = $array['rep'];
         $app_file = $array['file'];
         $app_active = $array['dscrip'];
         define('ACTIV_APP', $array['dscrip']);
         define('APP_ID', $array['id']);
         $this->application = (require_once CONTROLLER_REP . SLASH . $app_rep . SLASH . $app_file . '_c.php');
     }
     //end else
 }