当前位置: 首页>>代码示例>>PHP>>正文


PHP curPage函数代码示例

本文整理汇总了PHP中curPage函数的典型用法代码示例。如果您正苦于以下问题:PHP curPage函数的具体用法?PHP curPage怎么用?PHP curPage使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了curPage函数的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: curPage

<?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>";
    }
}
开发者ID:TexGG,项目名称:Libertempo,代码行数:21,代码来源:add_column_hr.php

示例2: die

 * @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
开发者ID:br0ziliy,项目名称:TeamPass,代码行数:31,代码来源:roles.php

示例3:

"><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()) {
开发者ID:TEJATJ,项目名称:BITSQ,代码行数:31,代码来源:header.php


注:本文中的curPage函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。