本文整理汇总了PHP中admin::admin_menu方法的典型用法代码示例。如果您正苦于以下问题:PHP admin::admin_menu方法的具体用法?PHP admin::admin_menu怎么用?PHP admin::admin_menu使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类admin
的用法示例。
在下文中一共展示了admin::admin_menu方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: L
" target="_blank" id="site_homepage"><?php
echo L('site_homepage');
?>
</a><span>|</span>
<a href="?m=member" target="_blank"><?php
echo L('member_center');
?>
</a><span>|</span>
<a href="?m=search" target="_blank" id="site_search"><?php
echo L('search');
?>
</a>
</div>
<ul class="nav white" id="top_menu">
<?php
$array = admin::admin_menu(0);
foreach ($array as $_value) {
if ($_value['id'] == 10) {
echo '<li id="_M' . $_value['id'] . '" class="on top_menu"><a href="javascript:_M(' . $_value['id'] . ',\'?m=' . $_value['m'] . '&c=' . $_value['c'] . '&a=' . $_value['a'] . '\')" hidefocus="true" style="outline:none;">' . L($_value['name']) . '</a></li>';
} else {
echo '<li id="_M' . $_value['id'] . '" class="top_menu"><a href="javascript:_M(' . $_value['id'] . ',\'?m=' . $_value['m'] . '&c=' . $_value['c'] . '&a=' . $_value['a'] . '\')" hidefocus="true" style="outline:none;">' . L($_value['name']) . '</a></li>';
}
}
?>
<li class="tab_web"><a href="javascript:;"><span><?php
echo $currentsite['name'];
?>
</span></a></li>
</ul>
</div>
</div>
示例2: public_map
public function public_map()
{
$array = admin::admin_menu(0);
$menu = array();
foreach ($array as $k => $v) {
$menu[$v['id']] = $v;
$menu[$v['id']]['childmenus'] = admin::admin_menu($v['id']);
}
$show_header = true;
include $this->admin_tpl('map');
}
示例3: defined
<?php
defined('IN_ADMIN') or exit('No permission resources.');
$pc_hash = $_SESSION['pc_hash'];
echo '<ul class="page-sidebar-menu"><li style="margin-bottom: 10px;"><div class="sidebar-toggler hidden-phone"></div></li>';
$i=0;
foreach($datas as $_m) {
$i++;
$first = $i==1?'style="display: block;"':'';
echo '<li class="open"><a href="javascript:;"><i class="icon-cogs"></i><span class="title">'.L($_m['name']).'</span><span class="arrow "></span><span class="selected"></span></a><ul class="sub-menu" '.$first.'>';
$sub_array = admin::admin_menu($_m['id']);
foreach($sub_array as $_key=>$l_m1) {
//附加参数
$data = $l_m1['data'] ? '&'.$l_m1['data'] : '';
$ajax_url = "javascript:_MP(".$l_m1['id'].",'?m=".$l_m1['m']."&c=".$l_m1['c']."&a=".$l_m1['a'].$data."');";
echo '<li id="_MP'.$l_m1['id'].'"><a class="fstart" href="'.$ajax_url.'">'.L($l_m1['name']).'</a></li>';
}
echo '</li></ul>';
}
echo '</ul>';
?>
示例4: defined
<?php
defined('IN_ADMIN') or exit('No permission resources.');
$pc_hash = $_SESSION['pc_hash'];
foreach ($datas as $_value) {
echo '<h3 class="f14"><span class="switchs cu on" title="' . L('expand_or_contract') . '"></span>' . L($_value['name']) . '</h3>';
echo '<ul>';
$sub_array = admin::admin_menu($_value['id']);
foreach ($sub_array as $_key => $_m) {
//附加参数
$data = $_m['data'] ? '&' . $_m['data'] : '';
if ($menuid == 5) {
//左侧菜单不显示选中状态
$classname = 'class="sub_menu"';
} else {
$classname = 'class="sub_menu"';
}
echo '<li id="_MP' . $_m['id'] . '" ' . $classname . '><a href="javascript:_MP(' . $_m['id'] . ',\'?m=' . $_m['m'] . '&c=' . $_m['c'] . '&a=' . $_m['a'] . $data . '\');" hidefocus="true" style="outline:none;">' . L($_m['name']) . '</a></li>';
}
echo '</ul>';
}
?>
<script type="text/javascript">
$(".switchs").each(function(i){
var ul = $(this).parent().next();
$(this).click(
function(){
if(ul.is(':visible')){
ul.hide();
$(this).removeClass('on');
}else{
示例5: L
}
?>
<ul>
<li class="title"><?php
echo L($v['name']);
?>
</li>
<?php
foreach ($v['childmenus'] as $k => $r) {
?>
<li class="title2"><?php
echo L($r['name']);
?>
</li>
<?php
$menus = admin::admin_menu($r['id']);
foreach ($menus as $s => $r) {
?>
<li><a href="javascript:go('index.php?m=<?php
echo $r['m'];
?>
&c=<?php
echo $r['c'];
?>
&a=<?php
echo $r['a'];
?>
&pc_hash=<?php
echo $_SESSION['pc_hash'];
?>
&menuid=<?php