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


PHP PMA_getHtmlForSubMenusOnUsersPage函数代码示例

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


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

示例1: testPMAGetHtmlForSubMenusOnUsersPage

 /**
  * Test for PMA_getHtmlForSubMenusOnUsersPage
  *
  * @return void
  */
 public function testPMAGetHtmlForSubMenusOnUsersPage()
 {
     $html = PMA_getHtmlForSubMenusOnUsersPage('server_privileges.php');
     //validate 1: topmenu2
     $this->assertContains('<ul id="topmenu2">', $html);
     //validate 2: tabactive for server_privileges.php
     $this->assertContains('<a class="tabactive" href="server_privileges.php', $html);
     $this->assertContains(__('User accounts overview'), $html);
     //validate 3: not-active for server_user_groups.php
     $this->assertContains('<a href="server_user_groups.php', $html);
     $this->assertContains(__('User groups'), $html);
 }
开发者ID:rclakmal,项目名称:phpmyadmin,代码行数:17,代码来源:PMA_server_users_test.php

示例2: PMA_getRelationsParam

 * functions implementation for this script
 */
require_once 'libraries/display_change_password.lib.php';
require_once 'libraries/server_privileges.lib.php';
$cfgRelation = PMA_getRelationsParam();
/**
 * Does the common work
 */
$response = PMA_Response::getInstance();
$header = $response->getHeader();
$scripts = $header->getScripts();
$scripts->addFile('server_privileges.js');
if (isset($_REQUEST['viewing_mode']) && $_REQUEST['viewing_mode'] == 'server' && isset($GLOBALS['cfgRelation']['menuswork']) && $GLOBALS['cfgRelation']['menuswork']) {
    include_once 'libraries/server_users.lib.php';
    $response->addHTML('<div>');
    $response->addHTML(PMA_getHtmlForSubMenusOnUsersPage('server_privileges.php'));
}
/**
 * Sets globals from $_POST patterns, for privileges and max_* vars
 */
$post_patterns = array('/_priv$/i', '/^max_/i');
PMA_setPostAsGlobal($post_patterns);
require 'libraries/server_common.inc.php';
/**
 * Messages are built using the message name
 */
$strPrivDescAllPrivileges = __('Includes all privileges except GRANT.');
$strPrivDescAlter = __('Allows altering the structure of existing tables.');
$strPrivDescAlterRoutine = __('Allows altering and dropping stored routines.');
$strPrivDescCreateDb = __('Allows creating new databases and tables.');
$strPrivDescCreateRoutine = __('Allows creating stored routines.');
开发者ID:xtreme-jamil-shamy,项目名称:phpmyadmin-cf,代码行数:31,代码来源:server_privileges.php

示例3:

$scripts  = $header->getScripts();
$scripts->addFile('server_user_groups.js');

/**
 * Only allowed to superuser
 */
if (! $GLOBALS['is_superuser']) {
    $response->addHTML(
        PMA\libraries\Message::error(__('No Privileges'))
            ->getDisplay()
    );
    exit;
}

$response->addHTML('<div>');
$response->addHTML(PMA_getHtmlForSubMenusOnUsersPage('server_user_groups.php'));

/**
 * Delete user group
 */
if (! empty($_REQUEST['deleteUserGroup'])) {
    PMA_deleteUserGroup($_REQUEST['userGroup']);
}

/**
 * Add a new user group
 */
if (! empty($_REQUEST['addUserGroupSubmit'])) {
    PMA_editUserGroup($_REQUEST['userGroup'], true);
}
开发者ID:nijel,项目名称:phpmyadmin,代码行数:30,代码来源:server_user_groups.php


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