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


PHP is_root函数代码示例

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


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

示例1: TFm2

 function TFm2()
 {
     global $str, $actions;
     TTable::TTable();
     $str[get_class_name($this)] = array_merge($str[get_class_name($this)], array('title' => array('Файловый менеджер', 'File Manager')));
     $field = get('field', false, 'gp');
     if ($field) {
         $actions[$this->name]['return'] = array('OK', 'OK', 'link' => "cnt.sendValues(); ", 'img' => '../third/restore_f2.png', 'display' => 'none');
     }
     $actions[$this->name]['load'] = array('Загрузить', 'Load', 'link' => "\n\t\t\t\t \t  cnt.document.getElementById('createForm').style.visibility='hidden';\n\t\t\t\t  \t  cnt.direction = -1;\n\t\t\t\t\t  cnt.startMainLoad();\n\t\t\t\t\t  cnt.showDownloadFrom();\n\t\t\t\t  ", 'img' => '../third/filesave.png', 'display' => 'none');
     $actions[$this->name]['create'] = array('Создать директорию', 'Create', 'link' => "\n\t\t\t\t \t  cnt.document.getElementById('downloadForm').style.visibility='hidden';\n\t\t\t\t  \t  cnt.direction = -1;\n\t\t\t\t\t  cnt.startMainLoad();\n\t\t\t\t\t  cnt.showCreateFrom();", 'img' => '../third/add_section.png', 'display' => 'none');
     $actions[$this->name]['delete'] = array('Удалить', 'Delete', 'link' => "cnt.Delete();", 'img' => '../third/cancel_f2.png', 'display' => 'none');
     $actions[$this->name]['rename'] = array('Переименовать', 'Rename', 'link' => "\n\t\t\t\t \t  cnt.document.getElementById('changenameForm').style.visibility='hidden';\n\t\t\t\t  \t  cnt.direction = -1;\n\t\t\t\t\t  cnt.startMainLoad();\n\t\t\t\t\t  cnt.showChangenameForm();", 'img' => '../third/menu.png', 'display' => 'none');
     $data = $this->ReadIni('modules/' . $this->name . '/module.ini');
     if (isset($data['module']['watermark']) && $data['module']['watermark']) {
         $actions[$this->name]['watermark'] = array('Водяной знак', 'Water Mark', 'link' => "\n\t\t\t\t\t \t  cnt.document.getElementById('watermarkForm').style.visibility='hidden';\n\t\t\t\t\t  \t  cnt.direction = -1;\n\t\t\t\t\t\t  cnt.startMainLoad();\n\t\t\t\t\t\t  cnt.showWatermarkForm();", 'img' => '../third/generic.png', 'display' => 'block');
     }
     $data['dirs'] = array();
     $data['defaults'] = array();
     $dir = FILES_DIR . domainRootId();
     if (!is_dir($dir) || is_root()) {
         $dir = FILES_DIR;
     }
     $data['dirs'][] = $dir;
     $data['defaults']['dir'] = $dir;
     $this->config = $data;
 }
开发者ID:romlg,项目名称:cms36,代码行数:27,代码来源:fm2.php

示例2: Show

 function Show()
 {
     if (!empty($GLOBALS['_POST'])) {
         $actions = get('actions', '', 'p');
         if ($actions) {
             return $this->{$actions}();
         }
     }
     $this->SetValues();
     require_once core('ajax_table');
     $data['thisname'] = $this->name;
     $data['root'] = is_root();
     $this->AddStrings($data);
     $_tables = sql_getRows('SHOW tables');
     foreach ($_tables as $key => $val) {
         $tables[$val] = $val;
     }
     $_transactions = sql_getColumn('SELECT distinct action FROM ' . $this->table . ' ORDER BY action');
     foreach ($_transactions as $key => $val) {
         $transactions[$val] = $val;
     }
     $where = '';
     if ($this->from_date && $this->to_date) {
         $where = ' UNIX_TIMESTAMP(date)>=' . $this->from_date . ' AND UNIX_TIMESTAMP(date)<=' . $this->to_date;
     }
     $data['table'] = ajax_table(array('columns' => array(array('select' => 'user', 'display' => 'user', 'width' => '1px', 'flags' => FLAG_SORT | FLAG_SEARCH), array('select' => 'object', 'display' => 'object', 'width' => '1px', 'flags' => FLAG_SORT | FLAG_FILTER | FLAG_SEARCH, 'filter_type' => 'array', 'filter_value' => array('' => '-- все --') + $tables, 'filter_rule' => 'find_in_set'), array('select' => 'action', 'display' => 'action', 'width' => '1px', 'flags' => FLAG_SORT | FLAG_FILTER | FLAG_SEARCH, 'filter_type' => 'array', 'filter_value' => array('' => '-- все --') + $transactions), array('select' => 'description', 'display' => 'description', 'type' => 'description', 'flags' => FLAG_SEARCH), array('select' => 'date', 'display' => 'date', 'type' => 'datetime', 'width' => '100px', 'flags' => FLAG_SORT)), 'from' => $this->table, 'where' => $where, 'orderby' => 'date DESC', 'params' => array('page' => $this->name, 'do' => 'show'), 'dblclick' => '', 'click' => ''), $this);
     $data['navig'] = $this->NavigForm();
     return $this->parse($data, $this->name . '.tmpl');
 }
开发者ID:romlg,项目名称:cms36,代码行数:29,代码来源:log_change.php

示例3: Show

 function Show()
 {
     if (!empty($GLOBALS['_POST'])) {
         $actions = get('actions', '', 'p');
         if ($actions) {
             return $this->{$actions}();
         }
     }
     require_once core('list_table');
     $data['thisname'] = $this->name;
     $logins = array('' => '-') + sql_getRows('SELECT DISTINCT login FROM ' . $this->table . ' ORDER BY login', true);
     $data['root'] = is_root();
     $this->AddStrings($data);
     $data['table'] = list_table(array('columns' => array(array('select' => 'login', 'display' => 'login', 'flags' => FLAG_SORT | FLAG_SEARCH | FLAG_FILTER, 'filter_type' => 'array', 'filter_value' => $logins), array('select' => 'ip', 'display' => 'ip', 'width' => '1px', 'flags' => FLAG_SORT | FLAG_SEARCH), array('select' => 'date', 'display' => 'date', 'type' => 'datetime', 'width' => '100px', 'flags' => FLAG_SORT)), 'from' => ' log_access ', 'orderby' => 'date DESC', 'params' => array('page' => $this->name, 'do' => 'show'), 'dblclick' => '', 'click' => ''), $this);
     $this->AddStrings($data);
     return $this->Parse($data, LIST_TEMPLATE);
 }
开发者ID:romlg,项目名称:cms36,代码行数:17,代码来源:log_access.php

示例4: Show

    function Show()
    {
        if (!empty($_POST)) {
            $action = get('actions', '', 'p');
            if ($action) {
                if ($this->Allow($action)) {
                    return $this->{$action}();
                } else {
                    return $this->alert_method_not_allowed();
                }
            }
        }
        require_once core('ajax_table');
        $client_id = get('client_id', 0, 'g');
        $ret['thisname'] = $this->name;
        $ret['table'] = ajax_table(array('columns' => array(array('select' => 'em.id', 'display' => 'id', 'type' => 'checkbox'), array('select' => 'COUNT(*)', 'as' => 'em_count'), array('select' => 'CONCAT(cl.name,CHAR(32),cl.lname,CHAR(32),"&lt;",cl.login,"&gt;")', 'as' => 'to_field', 'display' => $client_id ? NULL : 'to', 'type' => 'to'), array('select' => 'u.id', 'display' => $client_id || is_root() ? 'from' : NULL, 'type' => 'from'), array('select' => 'em.subject', 'display' => 'subject'), array('select' => 'UNIX_TIMESTAMP(em.date)', 'as' => 'from_date', 'display' => 'date', 'type' => 'datetime'), array('select' => 'CONCAT(u.fullname,CHAR(32),"&lt;",u.login,"&gt;")', 'as' => 'u_fullname')), 'from' => $this->table . ' AS em
							LEFT JOIN email_log AS log ON em.id=log.email_id
							LEFT JOIN auth_users AS cl ON log.client_id=cl.id
							LEFT JOIN users AS u ON em.user_id=u.id', 'where' => $client_id ? 'log.client_id=' . $client_id : '', 'orderby' => 'em.date DESC', 'groupby' => 'em.id', 'params' => array('page' => $this->name, 'do' => 'show', 'client_id' => $client_id), 'click' => 'ID=cb.value;', 'dblclick' => 'editItem(id)'), $this);
        return $this->Parse($ret, $this->name . '.tmpl');
    }
开发者ID:romlg,项目名称:cms36,代码行数:21,代码来源:sent_emails.php

示例5: DownloadFile

 function DownloadFile()
 {
     if (!is_root()) {
         return;
     }
     if (!$this->makeDir(BACKUP_DIR)) {
         return;
     }
     $filename = clearFileName($_GET['name']);
     if (!isBackupPathCorrect($filename)) {
         exit;
     }
     $dotpos = strrpos($filename, '.');
     switch (substr($filename, $dotpos + 1, strlen($filename) - $dotpos - 1)) {
         case "bz2":
             $mime_type = "application/x-bzip";
             break;
         case "gz":
             $mime_type = "application/x-gzip";
         default:
             $mime_type = "application/octet-stream";
     }
     if (!file_exists(BACKUP_DIR . '/' . $filename)) {
         exit;
     }
     ob_end_clean();
     Header('Content-Encoding: none');
     Header("Content-Type: " . $mime_type);
     header("Content-Disposition: attachment; filename=\"" . $filename . "\"");
     header("Expires: 0");
     header("Pragma: no-cache");
     $fp = fopen(BACKUP_DIR . '/' . $filename, 'rb');
     while (!feof($fp)) {
         echo fread($fp, 10240);
     }
     fclose($fp);
     exit;
 }
开发者ID:romlg,项目名称:cms36,代码行数:38,代码来源:mysqldump.php

示例6: helper_result

 if ($ftp->is_my_ftp($ftp_id) || is_root() || is_admin() && $ftp->is_my_ftp($ftp_id)) {
     $ftp->set_id($ftp_id);
     $ftp->get_ftp();
     echo $layout->title(txt('edit_ftp'), 'icon.png');
     echo $layout->txtdesc(txt('dsc_ftp_title'));
     echo helper_result('update_ftp');
     $form = new phpos_forms();
     echo $form->form_start('update_ftp', helper_ajax('section.edit_account.php'), array('app_params' => ''));
     $form->reload_after_submit(array('nowy'));
     $form->input('hidden', 'action', '', '', 'update_ftp');
     echo $layout->column('50%');
     $form->title($ftp->get_title(), null, ICONS . 'edit.png');
     $form->condition('not_null', true, txt('form_empty_field') . txt('title'));
     $form->input('text', 'ftp_new_title', txt('title'), txt('dsc_ftp_name'), $ftp->get_title());
     $form->input('text', 'ftp_new_desc', txt('desc'), txt('dsc_ftp_desc'), $ftp->get_desc());
     if (is_root() || is_admin()) {
         $items = array('0' => txt('no'), '1' => txt('yes'));
         $form->radio('ftp_new_public', txt('ftp_form_public'), txt('ftp_form_public_desc'), $items, $ftp->get_is_public());
     } else {
         $form->input('hidden', 'ftp_new_public', '', '', '0');
     }
     echo $form->render();
     echo $layout->end('column');
     echo $layout->column('50%');
     $form->title(txt('ftp_authentication'), '', ICONS . 'system_info/key_icon.png');
     $form->condition('not_null', true, txt('form_empty_field') . 'Host');
     $form->input('text', 'ftp_new_host', 'Host/IP', txt('dsc_ftp_host'), $ftp->get_host());
     $form->condition('not_null', true, txt('form_empty_field') . 'Login');
     $form->input('text', 'ftp_new_login', 'Login', txt('dsc_ftp_login'), $ftp->get_login());
     $form->condition('not_null', true, txt('form_empty_field') . txt('password'));
     $form->input('password', 'ftp_new_pass', txt('password'), txt('dsc_ftp_pass'), $ftp->get_password());
开发者ID:brian-clemont,项目名称:phpos,代码行数:31,代码来源:section.edit_account.php

示例7: die

        die('<strong style="color:orangered">[ ! ]  Cannot create cache folder. Please create it manually. It should have this address: <i>' . CACHE_DIR . '</i></strong>');
    }
}
?>


<?php 
$cnx = db_connect();
// is already installed?
if (mysql_query("DESCRIBE " . TBL_PREFIX . TBL_RECORDS, $cnx)) {
    ?>

  <h3 class="ko">smt2 is already installed</h3>
  <?php 
    // help the root user to unistall smt2 stuff
    $msg = is_root() ? 'you need to <a href="uninstall.php">uninstall here</a> first' : 'please delete all <em>' . TBL_PREFIX . '</em> tables from database';
    ?>
  <p>
    If you want to re-install it, <?php 
    echo $msg;
    ?>
.
  </p>
  
<?php 
} else {
    // before installing, ask user email (will be inserted on DB)
    if (isset($_POST['email'])) {
        $email = trim($_POST['email']);
    }
    // however, it can be changed later, so it won't be validated
开发者ID:sorincoza,项目名称:smt2-for-wordpress,代码行数:31,代码来源:install.php

示例8: unlink

<?php

if (empty($_POST)) {
    exit;
}
// server settings are required - relative path to smt2 root dir
require '../../../config.php';
// protect extension from being browsed by anyone
require SYS_DIR . 'logincheck.php';
// only the root user can delete logs
if (!is_root()) {
    die_msg($_loginMsg["NOT_ALLOWED"]);
}
if (isset($_GET['id'])) {
    $logQuery = "id='" . (int) $_GET['id'] . "'";
} else {
    if (isset($_GET['cid'])) {
        $logQuery = "client_id='" . $_GET['cid'] . "'";
    } else {
        if (isset($_GET['pid'])) {
            $pageId = (int) $_GET['pid'];
            $logQuery = "cache_id='" . $pageId . "'";
            // delete cached file
            $cacheQuery = "id='" . $pageId . "'";
            $page = db_select(TBL_PREFIX . TBL_CACHE, "file", $cacheQuery);
            if (is_file(CACHE_DIR . $page['file'])) {
                unlink(CACHE_DIR . $page['file']);
            }
            // now delete cache log
            db_delete(TBL_PREFIX . TBL_CACHE, $cacheQuery);
        }
开发者ID:sorincoza,项目名称:smt2-for-wordpress,代码行数:31,代码来源:delete.php

示例9:

        break;
}
if (defined('DESKTOP')) {
    $explorer->config('icon_size_class', 'phpos_icon_desktop_size_medium');
}
/*
**************************
*/
// Shortcucts for params
$action_id = $my_app->get_param('action_id');
$dir_id = $my_app->get_param('dir_id');
$root_id = $my_app->get_param('root_id');
/*
**************************
*/
if (globalconfig('readonly') && !is_root()) {
    $my_app->set_param('readonly', 1);
    $readonly = 1;
    cache_param('readonly');
}
/*
**************************
*/
// Actions (new dir, upload, etc)
include MY_APP_DIR . 'controllers/explorerControllerActions.php';
/*
**************************
*/
// Reset params
$my_app->set_param('action_id', null);
$my_app->set_param('action_param', null);
开发者ID:brian-clemont,项目名称:phpos,代码行数:31,代码来源:explorerController.php

示例10: txt

?>
startmenu/switch_arrow_right.png"  id="desktop_switch_right"  title="<?php 
echo txt('desktop_switch_tray_to_local');
?>
"/>
	</div>

</div>

<div id="phpos-menustart_Window_container"></div>
<div id="phpos-menustart_WindowApps_container">	<?php 
require_once PHPOS_DIR . 'controllers/menu_startAppsController.php';
?>
	</div>
<?php 
if (globalconfig('demo_mode') == 1 && !is_root()) {
    echo '<div id="phpos-menustart_Desktop_demo"><span style="font-size:24px">' . txt('demo_mode') . '</span><br />' . txt('demo_mode_desc') . '</div>';
}
?>
<div id="phpos-menustart_Desktop_info"><img src="<?php 
echo ICONS;
?>
desktop_switcher/db.png" style="display:inline-block; vertical-align:middle; padding-right:5px" /><b><?php 
echo txt('desktop_switch_up_desktop');
?>
</b> <?php 
echo txt('desktop_switch_up_db');
?>
</div>

<script>
开发者ID:brian-clemont,项目名称:phpos,代码行数:31,代码来源:menu_startController.php

示例11: GetTree

 /**
  * Построение дерева
  *
  * @param int $id - от какого элемента строить дерево
  * @param int $level
  * @param int $hidden - если hidden=0, то не показываем скрытые разделы
  * @param int root_id
  * @param array $params
  * @return unknown
  */
 function GetTree($id, $level = -1, $hidden = 1, $root_id, $params = array())
 {
     global $user;
     $level++;
     $root_id = $root_id ? $root_id : domainRootID();
     $deny_ids = '';
     if (!is_root() && !empty($user['deny_ids'])) {
         $deny_ids = $user['deny_ids'];
     }
     if (defined('LANG_SELECT') && LANG_SELECT) {
         $name_select = "IF (name_" . lang() . " <> '', name_" . lang() . ", name_" . LANG_DEFAULT . ") as name";
     } else {
         $name_select = "name";
     }
     if ($this->department_id) {
         $sql = "\n    \t\t\tSELECT\n    \t\t\t\tid, {$name_select}, next, visible, pid, priority, page, type, root_id, pids, level, dir, protected, is_link\n    \t\t\tFROM\n    \t\t\t\t" . $this->table . "\n    \t\t\tWHERE\n                    pid<>id\n                    " . ($this->pids[0] == $this->department_id && (int) $this->pids[$level] ? " AND pid=" . (int) $this->pids[$level] : ' AND pid=' . $this->department_id) . "\n                    " . (!$hidden ? " AND visible>'0'" : " AND visible>='0'") . "\n    \t\t\t\t" . ($deny_ids ? " AND id NOT IN (" . $deny_ids . ")" : "") . "\n    \t\t\tORDER BY\n    \t\t\t\tpriority, name\n    \t\t";
     } else {
         $sql = "\n\t\t\tSELECT\n\t\t\t\tid, {$name_select}, next, visible, pid, priority, page, type, root_id, pids, level, dir, protected, is_link\n\t\t\tFROM\n\t\t\t\t" . $this->table . "\n\t\t\tWHERE\n                root_id='" . $root_id . "'\n                " . ($this->pids[0] == $root_id && (int) $this->pids[$level] ? " AND pid=" . (int) $this->pids[$level] : ' AND pid=' . $root_id) . " AND pid<>id\n                " . (!$hidden ? " AND visible>'0'" : " AND visible>='0'") . "\n\t\t\t\t" . ($deny_ids ? " AND id NOT IN (" . $deny_ids . ")" : "") . "\n\t\t\tORDER BY\n\t\t\t\tpriority, name\n\t\t";
     }
     $rows = sql_getRows($sql);
     $items = array();
     if ($rows) {
         $hidden_url = !$hidden ? "&hidden=0" : "";
         foreach ($rows as $row) {
             $items[$row['id']] = $this->getOneItem($id, $row, $root_id, $hidden_url, $params);
             if ($this->department_root) {
                 if (is_array($this->pids) && $this->pids['0'] == $root_id && in_array($row['id'], $this->pids) && $row['id'] != $row['pid']) {
                     $items[$row['id']]['subtree'] = $this->GetTree($id, $level, $hidden, $root_id, $params);
                 }
             } else {
                 if (is_array($this->pids) && $this->pids['0'] == $this->department_id && in_array($row['id'], $this->pids) && $row['id'] != $row['pid']) {
                     $items[$row['id']]['subtree'] = $this->GetTree($id, $level, $hidden, $root_id, $params);
                 }
             }
         }
     }
     $items_data['items'] =& $items;
     if (count($rows) && $level > 0) {
         $items_data['ul_open'] = '<ul>';
         $items_data['ul_close'] = '</ul>';
     }
     $tpl = 'tree/tree.items.tmpl';
     if ($params['copy']) {
         $tpl = 'tree/tree.items_copy.tmpl';
     } elseif ($params['treeurl']) {
         $tpl = 'tree/treeurl/treeurl.items.tmpl';
     } elseif ($params['treeid']) {
         $tpl = 'tree/treeid/treeid.items.tmpl';
     } elseif ($params['checkboxtree']) {
         $tpl = 'tree/treecheck/treecheck.items.tmpl';
     }
     $tree = Parse($items_data, $tpl);
     return $tree;
 }
开发者ID:romlg,项目名称:cms36,代码行数:64,代码来源:tree.php

示例12: txt

						
						<div class="nav_icons_container">
						<?php 
echo $html['navbar'];
?>
						</div>
						
						<div class="nav_address_container">
					<?php 
echo $html['addressbar'];
?>
					</div>
					</div>

					<?php 
if (APP_ACTION == 'index' && $my_app->get_param('fs') == 'ftp' || $my_app->get_param('fs') == 'local_files' && (!$readonly && globalconfig('disable_upload') != 1 || is_root())) {
    ?>
					<div id="phpos_explorer_uploader_container" class="easyui-tooltip" title="<?php 
    echo txt('tip_explorer_upload_file');
    ?>
">
						<form enctype="multipart/form-data" method="post" action="<?php 
    echo helper_post('null', array('fs' => $app_param['fs']));
    ?>
" id="upload" style="background: transparent"> 
						
							<input type="hidden" name="phpos_upload" value="1"> 
							<input type="hidden" name="posttest" value="postyes"> 
						
							<img style="height:29px" valign="middle" src="<?php 
    echo PHPOS_WEBROOT_URL;
开发者ID:brian-clemont,项目名称:phpos,代码行数:30,代码来源:inc.explorer_toolbar.php

示例13: first_replace

*
* изменения by xfox@rusoft.ru 2006-08:
* + дамп работает как подключаемый файл в движке
* + вывод кешируется в файл
* + соединение поддерживается передачей символов раз в секунду
* - исключен формат .zip
* + файл не отдается пользователю сразу, он сбрасывается на сервер
*   и js возвращает ссылку для его загрузки
*****************************************************************************/
/**
 * Get the variables sent or posted to this script and a core script
 */
$GLOBALS['ob_mode'] = 1;
$GLOBALS['gzip'] = false;
# check rights
if (!is_root() && $user['rights']['mysqldump'] != 15) {
    die("Access denied.");
}
define("EXT_INC_COL", 100);
# max allowed count of extended insert syntax
$db = $_POST["db"];
$GLOBALS['asfile'] = $asfile = $_POST["as"] != "data";
header('Content-Encoding: none');
ob_end_clean();
echo "<html><head><title>Processing database</title></head>\n<body>Dumping: \n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r";
flush();
function first_replace($from, $to, $str)
{
    $pos = strpos($str, $from);
    $start = substr($str, 0, $pos);
    $end = substr($str, $pos + strlen($from), strlen($str) - $pos - strlen($from));
开发者ID:romlg,项目名称:cms36,代码行数:31,代码来源:tbl_dump.php

示例14: array

 
**********************************
*/
if (!defined('PHPOS')) {
    die;
}
global $my_app;
$workgroup_id = $my_app->get_param('workgroup_id');
$app_menu = array('title:' . txt('my_server') . ',action:actionGoServer,icon:icon-myserver');
if (is_root() || is_admin()) {
    $app_menu[] = 'title:' . txt('group_section_new_group') . ',action:actionNewGroup,icon:icon-edit_add';
    $app_menu[] = 'title:' . txt('group_section_list') . ',action:actionManageGroups,icon:icon-group';
}
if (!empty($workgroup_id)) {
    $check_group = new phpos_groups();
    if (is_root() || is_admin() && $check_group->im_owner($workgroup_id)) {
        $app_menu[] = 'title:' . txt('group_section_edit_group') . ',action:actionEditGroup,icon:icon-edit';
        $app_menu[] = 'title:' . txt('group_section_group_users') . ',action:actionEditGroupUsers,icon:icon-user';
    }
}
function actionEditGroup($menu_item)
{
    global $my_app;
    $j = winopen(txt('group_section_edit_group'), 'cp', 'app_id:groups@groups_admin', 'section:edit_group,group_id:' . $my_app->get_param('workgroup_id'));
    return $j;
}
function actionEditGroupUsers($menu_item)
{
    global $my_app;
    $j = winopen(txt('group_section_edit_group'), 'cp', 'app_id:groups@groups_admin', 'section:group_users,group_id:' . $my_app->get_param('workgroup_id'));
    return $j;
开发者ID:brian-clemont,项目名称:phpos,代码行数:30,代码来源:workgroupMenu.php

示例15: glob

*/
if (!defined('PHPOS')) {
    die;
}
$tray_icons = glob(PHPOS_DIR . 'plugins/tray.*.php');
$tray_data = array();
foreach ($tray_icons as $tray_plugin) {
    $tray = array();
    include $tray_plugin;
    $tray_data[] = $tray;
}
$c = count($tray_data);
if ($c != 0) {
    for ($i = 0; $i < $c; $i++) {
        $this_tray = $tray_data[$i];
        if ($this_tray['access_level'] < 2 || $this_tray['access_level'] == 2 && is_admin() || is_root()) {
            $wintask = new api_wintask();
            $wintask->setContextMenu($this_tray['context_menu']);
            $js_context_menu .= $wintask->contextMenuRender('phpos_tray_icon_' . $this_tray['id'], 'img', 'left');
            $txt = '';
            if (!empty($this_tray['txt'])) {
                $txt = '<span>' . $this_tray['txt'] . '</span>';
            }
            if ($this_tray['use_custom_icons']) {
                echo '<div id="phpos_tray_icon_' . $this_tray['id'] . '" title="' . $this_tray['title'] . '" class="phpos_tray_item phpos_tray_item_mouseleave"><img src="' . $this_tray['icons'][0] . '" />' . $txt . '</div>';
            } else {
                echo '<div id="phpos_tray_icon_' . $this_tray['id'] . '" title="' . $this_tray['title'] . '" class="phpos_tray_item phpos_tray_item_mouseleave"><img  src="' . PHPOS_WEBROOT_URL . '_phpos/icons_tray/' . $this_tray['icons'][0] . '" />' . $txt . '</div>';
            }
        }
    }
}
开发者ID:brian-clemont,项目名称:phpos,代码行数:31,代码来源:menu_startTrayController.php


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