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


PHP UI::lang方法代码示例

本文整理汇总了PHP中UI::lang方法的典型用法代码示例。如果您正苦于以下问题:PHP UI::lang方法的具体用法?PHP UI::lang怎么用?PHP UI::lang使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在UI的用法示例。


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

示例1: MP

 function MP($p = NULL, $T = "Permission_Denied", $url = __REF__)
 {
     if (self::$Rs->groupid == "1") {
         return TRUE;
     }
     if (is_array($p) ? array_intersect($p, self::$power) : in_array($p, self::$power)) {
         return TRUE;
     } else {
         if ($T == 'F') {
             return FALSE;
         } else {
             echo UI::lang($T);
             exit;
         }
     }
 }
开发者ID:idreamsoft,项目名称:iCMS5.0,代码行数:16,代码来源:admin.class.php

示例2: foreach

    </tr>
    <tr class="nobg">
      <td class="td80">模块说明:</td>
      <td class="rowform"><textarea  rows="6" onkeyup="textareasize(this)" name="desc" id="desc" cols="50" class="tarea"><?php 
echo $rs['desc'];
?>
</textarea></td>
      <td class="tips2" colspan="2">100字以内</td>
    </tr>
    <tr class="nobg">
      <td class="td80">菜单位置:</td>
      <td class="rowform"><?php 
foreach (menu::load() as $H => $value) {
    if ($rs['table'] != $H) {
        $rs['position'] == $H && ($checked = ' checked="checked" ');
        echo '<span id="pos' . $H . '" class="pos"></span><input type="radio" name="position" class="radio" value="' . $H . '"' . $checked . '/> ' . UI::lang('header_' . $H) . '<br /><br />';
    }
}
?>
</td>
      <td class="tips2" colspan="2">选择菜单所在位置</td>
    </tr>
    <thead>
      <tr>
        <th colspan="4">快捷链接</th>
      </tr>
    </thead>
    <tr class="nobg">
      <td class="td80">链接名:</td>
      <td class="rowform"><input name="table" type="text" id="table" value="<?php 
echo $rs['table'];
开发者ID:idreamsoft,项目名称:iCMS5.0,代码行数:31,代码来源:models.add.php

示例3: domanage

 function domanage()
 {
     $mid = $_GET['mid'];
     $model = model::data($mid);
     $table = $model['tbn'];
     $forum = new forum();
     $fid = (int) $_GET['fid'];
     $type = $_GET['type'];
     $sql = " where ";
     switch ($type) {
         //postype: [0:用户][1:管理员] status:[0:草稿][1:正常][2:回收]
         case 'draft':
             //草稿
             $sql .= "`status` ='0' AND `postype`='1'";
             $_ptxt = array(0 => '发布', 1 => '转成草稿');
             $position = UI::lang("menu_article_draft");
             break;
         case 'trash':
             //回收站
             $sql .= "`status` ='2'";
             $_ptxt = array(0 => '还原', 1 => '放入回收站');
             $position = UI::lang("menu_article_trash");
             break;
         case 'user':
             //用户
             if ($_GET['act'] == "draft") {
                 $sql .= "`status` ='0'";
                 //用户审核
                 $position = UI::lang("menu_article_user_draft");
             } elseif ($_GET['act'] == "trash") {
                 $sql .= "`status` ='2'";
                 //用户回收站
                 $position = UI::lang("menu_article_user_trash");
             } else {
                 $sql .= "`status` ='1'";
                 $position = UI::lang("menu_article_user_manage");
             }
             $sql .= " AND `postype`='0'";
             $_ptxt = array(0 => '通过审核', 1 => '取消审核');
             break;
         default:
             $sql .= " `status` ='1' AND `postype`='1'";
             $position = '';
             $fid && ($position = $forum->forum[$fid]['name']);
     }
     $position && ($position = "&nbsp;&raquo;&nbsp;" . $position);
     if ($_GET['keywords']) {
         if ($_GET['st'] == "title") {
             $sql .= " AND `title` REGEXP '{$_GET['keywords']}'";
         } else {
             if ($_GET['st'] == "top") {
                 $sql .= " AND `top`='{$_GET['keywords']}'";
             } else {
                 if ($_GET['st'] == "id") {
                     $sql .= " AND `id` REGEXP '{$_GET['keywords']}'";
                 }
             }
         }
     }
     $_GET['title'] && ($sql .= " AND `title` like '%{$_GET['title']}%'");
     $_GET['tag'] && ($sql .= " AND `tags` REGEXP '[[:<:]]" . preg_quote(rawurldecode($_GET['tag']), '/') . "[[:>:]]'");
     isset($_GET['at']) && $_GET['at'] != '-1' && ($sql .= " AND `type` ='" . $_GET['at'] . "'");
     isset($_GET['userid']) && ($sql .= " AND `userid`='" . (int) $_GET['userid'] . "'");
     $fid = member::CP($fid) ? $fid : "0";
     if ($fid) {
         $fidIN = $forum->fid($fid) . $fid;
         if (isset($_GET['sub']) && strstr($fidIN, ',')) {
             $sql .= " AND fid IN(" . $fidIN . ")";
         } else {
             $sql .= " AND fid ='{$fid}'";
         }
         //$sql.=" OR `vlink` REGEXP '[[:<:]]".preg_quote($fid, '/')."[[:>:]]')";
     } else {
         member::$cpower && ($sql .= " AND fid IN(" . implode(',', (array) member::$cpower) . ")");
     }
     $_GET['starttime'] && ($sql .= " and `pubdate`>='" . strtotime($_GET['starttime']) . "'");
     $_GET['endtime'] && ($sql .= " and `pubdate`<='" . strtotime($_GET['endtime']) . "'");
     $act == 'user' && ($uri .= '&act=user');
     $_GET['type'] == 'draft' && ($uri .= '&type=draft');
     isset($_GET['userid']) && ($uri .= '&userid=' . (int) $_GET['userid']);
     isset($_GET['keyword']) && ($uri .= '&keyword=' . $_GET['keyword']);
     isset($_GET['tag']) && ($uri .= '&tag=' . $_GET['tag']);
     $orderby = $_GET['orderby'] ? $_GET['orderby'] : "id DESC";
     $maxperpage = (int) $_GET['perpage'] > 0 ? $_GET['perpage'] : 20;
     $total = $page == 1 || empty($_GET['rowNum']) ? iCMS_DB::getValue("SELECT count(*) FROM `#iCMS@__{$table}` {$sql}") : (int) $_GET['rowNum'];
     page($total, $maxperpage, "条记录");
     $rs = iCMS_DB::getArray("SELECT * FROM `#iCMS@__{$table}` {$sql} order by {$orderby} LIMIT {$this->firstcount} , {$maxperpage}");
     $_count = count($rs);
     include admincp::tpl();
 }
开发者ID:idreamsoft,项目名称:iCMS5.1,代码行数:90,代码来源:content.mo.php

示例4:

                ?>
 </dd>
            <?php 
            }
        } else {
            ?>
            <dd style="float:left; width:20%">
              <input name="power[]" type="checkbox" class="checkbox" value="<?php 
            echo $key;
            ?>
" parent="header_<?php 
            echo $H;
            ?>
"/>
              <?php 
            echo UI::lang($key);
            ?>
 </dd> 
            <?php 
        }
    }
    ?>
          </dl></td>
      </tr>
    </tbody>
    <?php 
}
?>
    <tr>
      <td><input type="submit" class="submit" name="forumlinksubmit" value="提交"  /></td>
    </tr>
开发者ID:idreamsoft,项目名称:iCMS5.1,代码行数:31,代码来源:account.power.php

示例5: doManage

 function doManage()
 {
     $mtime = microtime();
     $mtime = explode(' ', $mtime);
     $time_start = $mtime[1] + $mtime[0];
     Admin::MP(array("menu_article_manage", "menu_article_draft", "menu_article_user_manage", "menu_article_user_draft"));
     $forum = new forum();
     $fid = (int) $_GET['fid'];
     $type = $_GET['type'];
     $sql = " where ";
     switch ($type) {
         //postype: [0:用户][1:管理员][2:回收] status:[0:隐藏][1:正常]
         case 'draft':
             //草稿
             $sql .= "`status` ='0' AND `postype`='1'";
             $_ptxt = array(0 => '发布', 1 => '转成草稿');
             $position = UI::lang("menu_article_draft");
             break;
         case 'trash':
             //回收站
             $sql .= "`status` ='0' AND `postype`='2'";
             $_ptxt = array(0 => '还原', 1 => '放入回收站');
             $position = UI::lang("menu_article_trash");
             break;
         case 'user':
             //用户
             if ($_GET['act'] == "draft") {
                 $sql .= "`status` ='0'";
                 //用户审核
                 $position = UI::lang("menu_article_user_draft");
             } else {
                 $sql .= "`status` ='1'";
                 $position = UI::lang("menu_article_user_manage");
             }
             $sql .= " AND `postype`='0'";
             $_ptxt = array(0 => '通过审核', 1 => '取消审核');
             break;
         default:
             $sql .= " `status` ='1' AND `postype`='1'";
             $position = '';
             $fid && ($position = $forum->forum[$fid]['name']);
     }
     $position && ($position = "&nbsp;&raquo;&nbsp;" . $position);
     if ($_GET['keywords']) {
         if ($_GET['st'] == "title") {
             $sql .= " AND `title` REGEXP '{$_GET['keywords']}'";
         } else {
             if ($_GET['st'] == "top") {
                 $sql .= " AND `top`='{$_GET['keywords']}'";
             } else {
                 if ($_GET['st'] == "id") {
                     $sql .= " AND `id` REGEXP '{$_GET['keywords']}'";
                 } else {
                     if ($_GET['st'] == "tkd") {
                         $sql .= " AND CONCAT(title,keywords,description) REGEXP '{$_GET['keywords']}'";
                     }
                 }
             }
         }
     }
     $_GET['title'] && ($sql .= " AND `title` like '%{$_GET['title']}%'");
     $_GET['tag'] && ($sql .= " AND `tags` REGEXP '[[:<:]]" . preg_quote(rawurldecode($_GET['tag']), '/') . "[[:>:]]'");
     isset($_GET['at']) && $_GET['at'] != '-1' && ($sql .= " AND `type` ='" . $_GET['at'] . "'");
     isset($_GET['userid']) && ($sql .= " AND `userid`='" . (int) $_GET['userid'] . "'");
     $fid = Admin::CP($fid) ? $fid : "0";
     if ($fid) {
         $fidIN = $forum->fid($fid) . $fid;
         if (isset($_GET['sub']) && strstr($fidIN, ',')) {
             $sql .= " AND fid IN(" . $fidIN . ")";
         } else {
             $sql .= " AND fid ='{$fid}'";
         }
         //$sql.=" OR `vlink` REGEXP '[[:<:]]".preg_quote($fid, '/')."[[:>:]]')";
     } else {
         Admin::$cpower && ($sql .= " AND fid IN(" . implode(',', (array) Admin::$cpower) . ")");
     }
     isset($_GET['nopic']) && ($sql .= " AND `isPic` ='0'");
     $_GET['starttime'] && ($sql .= " and `pubdate`>='" . strtotime($_GET['starttime']) . "'");
     $_GET['endtime'] && ($sql .= " and `pubdate`<='" . strtotime($_GET['endtime']) . "'");
     $act == 'user' && ($uri .= '&act=user');
     $_GET['type'] == 'draft' && ($uri .= '&type=draft');
     isset($_GET['userid']) && ($uri .= '&userid=' . (int) $_GET['userid']);
     isset($_GET['keyword']) && ($uri .= '&keyword=' . $_GET['keyword']);
     isset($_GET['tag']) && ($uri .= '&tag=' . $_GET['tag']);
     $orderby = $_GET['orderby'] ? $_GET['orderby'] : "id DESC";
     $maxperpage = (int) $_GET['perpage'] > 0 ? $_GET['perpage'] : 20;
     $total = $page == 1 || empty($_GET['rowNum']) ? iCMS_DB::getValue("SELECT count(*) FROM `#iCMS@__article` {$sql}") : (int) $_GET['rowNum'];
     page($total, $maxperpage, "篇文章");
     $rs = iCMS_DB::getArray("SELECT * FROM `#iCMS@__article` {$sql} order by {$orderby} LIMIT {$this->firstcount} , {$maxperpage}");
     //echo iCMS_DB::$last_query;
     //iCMS_DB::last_query='explain '.iCMS_DB::$last_query;
     //$explain=iCMS_DB::getRow(iCMS_DB::last_query);
     //var_dump($explain);
     $_count = count($rs);
     include admincp::tpl("article.manage");
     //		$mtime = microtime();
     //		$mtime = explode(' ', $mtime);
     //		$time_end = $mtime[1] + $mtime[0];
     //		echo  "<h1>".($time_end - $time_start);
 }
开发者ID:idreamsoft,项目名称:iCMS5.0,代码行数:100,代码来源:article.mo.php

示例6: li

 function li($T, $A)
 {
     if (is_array($A)) {
         $i = 0;
         foreach ($A as $k => $v) {
             if (member::MP($k, 'F')) {
                 $href = strstr($v, 'http://') === false ? __SELF__ . '?mo=' . $v : $v;
                 $onClick = 'main_frame_src(\'' . $href . '\')';
                 if ($i % 2) {
                     echo '<li class="menu_title sub_right" onclick="' . $onClick . '"><b class="border"></b><span><a href="' . $href . '" target="main" hidefocus=true>' . UI::lang($k) . '</a></span></li>';
                 } else {
                     echo '<li class="menu_title sub_left" onclick="' . $onClick . '"><span><a href="' . $href . '" target="main" hidefocus=true>' . UI::lang($k) . '</a></span></li>';
                 }
                 $i++;
             }
         }
     } else {
         if (member::MP($T, 'F')) {
             list($type, $url) = explode(':', $A);
             if ($type == "javascript") {
                 $onClick = $url;
                 $href = 'javascript:' . $onClick;
                 echo '<li class="menu_title" onclick="' . $onClick . '"><span>' . UI::lang($T) . '</span></li>';
             } else {
                 $href = strstr($A, 'http://') === false ? __SELF__ . '?mo=' . $A : $A;
                 $onClick = 'main_frame_src(\'' . $href . '\')';
                 echo '<li class="menu_title" onclick="' . $onClick . '"><span><a href="' . $href . '" target="main" hidefocus=true>' . UI::lang($T) . '</a></span></li>';
             }
         }
     }
 }
开发者ID:idreamsoft,项目名称:iCMS5.1,代码行数:31,代码来源:menu.class.php

示例7: exit

<?php

/**
 * @package iCMS
 * @copyright 2007-2010, iDreamSoft
 * @license http://www.idreamsoft.com iDreamSoft
 * @author coolmoo <idreamsoft@qq.com>
 */
!defined('iPATH') && exit('What are you doing?');
?>

<div class="sidebarmenu">
  <div class="sidebarmenu-inner">
    <div class="sidebarmenu-list">
      <ul>
<?php 
$mid = (int) $_GET['mid'];
$model = $this->iCMS->getCache('system/models.cache', $mid);
if ($model['show']) {
    $aText = UI::lang('header_' . $model['table']);
    $aUrl = './index.php?mo=content&mid=' . $model['id'] . '&table=' . $model['table'];
    echo '<li><a style="background-image:url(./images/icons/article_write.gif);"  href="' . $aUrl . '&do=add">我要投稿</a></li>';
    echo '<li><a style="background-image:url(./images/icons/default.gif);" href="' . $aUrl . '">我的' . $aText . '</a></li>';
    echo '<li><a style="background-image:url(./images/icons/doing.gif);"  href="./index.php?mo=comment&mid=' . $model['id'] . '">' . $aText . '评论</a></li>';
}
?>
      </ul>
    </div>
  </div>
</div>
开发者ID:idreamsoft,项目名称:iCMS5.1,代码行数:30,代码来源:content.menu.php

示例8: foreach

}
$siteportalnav .= '<li class="usercenter"><a' . $aClass . ' href="./index.php"><span><strong>用户中心</strong></span></a></li>';
if ($this->module == 'article') {
    $bClass = ' class="current"';
    $navText = '资讯中心';
}
$siteportalnav .= '<li><a' . $bClass . ' href="./index.php?mo=article"><span><strong>资讯中心</strong></span></a></li>';
$table = $_GET['table'];
$menuArray = self::load();
foreach ($menuArray as $key => $menus) {
    $mKey = 'header_' . $key;
    if ($this->module == $key || $table == $key) {
        $cClass = ' class="current"';
        $navText = UI::lang($mKey) . '中心';
    }
    $siteportalnav .= '<li><a' . $cClass . ' href="./index.php?mo=' . $menus['href'] . '"><span><strong>' . UI::lang($mKey) . '中心</strong></span></a></li>';
}
$siteportalnav .= '</ul>';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php 
echo iCMS_CHARSET;
?>
">
<title><?php 
echo $navText;
?>
 - <?php 
echo $this->iCMS->config['name'];
开发者ID:idreamsoft,项目名称:iCMS5.1,代码行数:31,代码来源:usercp.php


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