コード例 #1
0
ファイル: add_column_hr.php プロジェクト: TexGG/Libertempo
<?php

$local_scripts = curPage();
if ($local_scripts[0] == "hr_index.php") {
    $pattern = "&onglet=";
    $i = 0;
    $which_onglet = explode($pattern, $local_scripts[1]);
    echo '<LINK href="' . ROOT_PATH . 'include/plugins/cet/css/bulles.css" title="bulles" rel="stylesheet" type="text/css">';
    if (empty($which_onglet) || $which_onglet[1] == "page_principale" || $which_onglet[0] == $local_scripts[1]) {
        $select_all_cet = "SELECT u_nom,u_prenom,pc_jours_demandes,pc_u_login,pc_requested_date,pc_comments FROM conges_users,conges_plugin_cet WHERE `conges_users`.`u_login`=`conges_plugin_cet`.`pc_u_login`";
        $exec_all_cet = \includes\SQL::query($select_all_cet);
        echo "<script>\n        \$(document).ready(function(){\n            \$('th:last-child').after('<th>CET</th>');";
        if ($exec_all_cet->num_rows != 0) {
            while ($user_cet = $exec_all_cet->fetch_array()) {
                echo "\n                var tableRow = \$('tr:has(td:contains(\"" . $user_cet['u_nom'] . "\")):has(td:contains(\"" . $user_cet['u_prenom'] . "\"))');\n                tableRow.css('color','blue');\n                var jours_demandes = Math.round(" . $user_cet['pc_jours_demandes'] . ")\n                tableRow.append('<td class=\"cet\" id=\"cet_" . $user_cet['pc_u_login'] . "_" . $i . "\"><b>'+jours_demandes+'</b><span class=\"cet_detail\">details : " . $user_cet['pc_requested_date'] . ". " . $user_cet['pc_comments'] . "</span></td>');\n                addHover('" . $user_cet['pc_u_login'] . "_" . $i . "');\n                ";
                $i++;
            }
        }
        echo "\n        function addHover(uid) {\n        var td_id = '#cet_'+uid;\n            \$(td_id).mouseover(function(){\n                \$(this).children('span').show();\n              }).mouseout(function(){\n                \$(this).children('span').hide();\n              });\n        }\n        });\n        </script>";
    }
}
コード例 #2
0
ファイル: roles.php プロジェクト: br0ziliy/TeamPass
 * @author        Nils Laumaillé
 * @version       2.1.25
 * @copyright     (c) 2009-2015 Nils Laumaillé
 * @licensing     GNU AFFERO GPL 3.0
 * @link          http://www.teampass.net
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 */
if (!isset($_SESSION['CPM']) || $_SESSION['CPM'] != 1 || !isset($_SESSION['user_id']) || empty($_SESSION['user_id']) || !isset($_SESSION['key']) || empty($_SESSION['key'])) {
    die('Hacking attempt...');
}
/* do checks */
require_once $_SESSION['settings']['cpassman_dir'] . '/sources/checks.php';
if (!checkUser($_SESSION['user_id'], $_SESSION['key'], curPage())) {
    $_SESSION['error']['code'] = ERR_NOT_ALLOWED;
    //not allowed page
    include $_SESSION['settings']['cpassman_dir'] . '/error.php';
    exit;
}
//load help
require_once $_SESSION['settings']['cpassman_dir'] . '/includes/language/' . $_SESSION['user_language'] . '_admin_help.php';
require_once $_SESSION['settings']['cpassman_dir'] . '/sources/main.functions.php';
//Get full list of groups
$arr_groups = array();
$rows = DB::query("SELECT id,title FROM " . prefix_table("nested_tree"));
foreach ($rows as $reccord) {
    $arr_groups[$reccord['id']] = $reccord['title'];
}
//display
コード例 #3
0
ファイル: header.php プロジェクト: TEJATJ/BITSQ
"><img src="<?php 
echo BASE_URI;
?>
background1.jpg" height="40px" width="100px" style="margin-top:-13px;"></a>
					
				</div>
				
				<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
					<form class="navbar-form navbar-left" role="search" name="searchResult" action="searchResult.php" method="POST">
								<input id="search" name="search" type="text" name="typeahead" class="typeahead tt-query" autocomplete="off" style="width:350px;color:black;" spellcheck="false" placeholder="Search Topics By Name, User, Mail or Category">
					</form>	
					
					<ul  class="nav navbar-nav navbar-right">
					
						<li><a id="nolink" href="index.php" class="<?php 
if (curPage() == "index.php") {
    echo 'active';
}
?>
"><span class="icon-bar"><i class="fa fa-home"></i></span>Home</a></li>
						<li><a id="notiLink"  onclick="toggleNotifications('show');" style="color:#888888;cursor:pointer"><i class="fa fa-bell"></i>Notifications<span id="notinumberbadge2" class="badge" style="background:#A20;"><?php 
$b = notify_number();
if ($b == 0) {
    echo '0';
} else {
    echo $b;
}
?>
</span></a></li>
						<li><a href="<?php 
if (!isLoggedIn()) {