/source/gl/power.php
http://prosporous.googlecode.com/ · PHP · 67 lines · 56 code · 0 blank · 11 comment · 29 complexity · a3d14fbb8b946b09dac3c3dc7e38647d MD5 · raw file
- <?php
- /* * ??????UTF-8???.
- * Created on 2010-5-29
- *
- * @author EXT <isrn@qq.com>
- *
- */
- function getright($tid, $right) {
- global $_SESSION;
- if ($_SESSION['rcg'] == 'A') {
- return 1;
- } else {
- return $_SESSION['rcg'][$right][$tid];
- }
- }
- switch ($_SERVER['PHP_SELF']) {
- case Sf(HTLJ, $_SERVER['PHP_SELF']): {
- iniJs('ext');
- Tr($jsstr, 'showjs');
- if ($_SESSION['logined'] != '1') {
- $xajax = new xajax("./ajax/xajax_suo.php");
- $xajax->configure('javascript URI', Js_path . "/Plug-in/xajax/");
- $xajax->registerFunction("loadsuo");
- Tr(Sys::Gv(), 'site_config');
- $Tp->assign('ajax', $xajax->getJavascript());
- Ts('login' . $_SESSION['HTLG'] . '.html');
- exit;
- }
- if ($_SERVER['HTTP_REFERER'] == '' && !Sf('index.php', $_SERVER['PHP_SELF'])) {
- // if(($_GET['mid']==''||$_GET['from']!='b') && !Sf('treedata.php',$_SERVER['PHP_SELF'])) {
- // Ja('??????');
- exit;
- }
- if ($_SESSION['rcg'] != 'A') {
- $tzurl = '/' . HTLJ . 'error.htm';
- if (Sf('show1/l.php', $_SERVER['PHP_SELF'])) {
- if (!$_SESSION['rcg']['r'][$_REQUEST['tid']] && $_GET['op'] == 'list') {
- Ja('??????', $tzurl);
- exit;
- }
- }
- if (Sf('show1/i.php', $_SERVER['PHP_SELF'])) {
- if ($_GET['op'] == 'add' && !$_GET['id'] && !$_SESSION['rcg']['c'][$_REQUEST['tid']]) {
- //print_r($_SESSION['rcg']);
- Ja('??????', $tzurl);
- exit;
- }
- }
- if (Sf('show1/i.php', $_SERVER['PHP_SELF'])) {
- if ($_GET['op'] == 'add' && $_GET['id'] && !$_SESSION['rcg']['u'][$_REQUEST['tid']]) {
- //print_r($_SESSION['rcg']);
- Ja('??????', $tzurl);
- exit;
- }
- }
- if (Sf('show1/l.php', $_SERVER['PHP_SELF'])) {
- if ($_REQUEST['op'] == 'del' && !$_SESSION['rcg']['d'][$_REQUEST['tid']]) {
- //print_r($_SESSION['rcg']);
- Ja('??????', $tzurl);
- exit;
- }
- }
- }
- break;
- }
- }
- ?>