本文整理汇总了PHP中Menu::getMenus方法的典型用法代码示例。如果您正苦于以下问题:PHP Menu::getMenus方法的具体用法?PHP Menu::getMenus怎么用?PHP Menu::getMenus使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Menu
的用法示例。
在下文中一共展示了Menu::getMenus方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
echo SERVER_URL;
?>
" ><span ><font style="font-size: 48px; font-weight: bold;color: #FE980F;">L</font><span style="font-size: 32px;">egal Lawyer</span> </span></a>
</div>
</div>
<div class="col-sm-8">
<div class="shop-menu pull-right">
<?php
if (Session::read("access_type")) {
$access_id = Session::read("access_type");
} else {
$access_id = 0;
}
$access_type = Validation::getAccessType($access_id);
$category_name = "Header";
$menus = Menu::getMenus($access_type, $category_name);
$subUrl = Menu::getMenuSubUrl($access_type);
?>
<ul class="nav navbar-nav">
<?php
foreach ($menus as $menu_key => $menu_value) {
$class = "";
if (isset($pageDetails[0]["url"]) && $menu_value['url'] == $pageDetails[0]["url"]) {
$class = 'class="active"';
}
?>
<li><a href="<?php
echo SERVER_URL;
?>
/<?php
echo $subUrl;
示例2: array
$themePath = Yii::app()->theme->baseUrl;
$cs->registerCoreScript('jquery.ui')->registerScriptFile($baseUrl . '/' . $themePath . '/js/lib/jquery.mjs.nested.sortable.js', CClientScript::POS_END);
?>
<div class="form row">
<?php
$form = $this->beginWidget('application.widgets.SnapActiveForm', array('id' => 'menu-form', 'enableAjaxValidation' => false, 'htmlOptions' => array('class' => 'col-md-12')));
?>
<?php
echo $form->errorSummary($model);
?>
<ul class="nav nav-tabs">
<?php
foreach (Menu::getMenus() as $Menu) {
?>
<li class="<?php
echo $Menu->id == $model->id ? 'active' : '';
?>
"><?php
echo CHtml::link($Menu->name, array('menu/update', 'id' => $Menu->id));
?>
</li>
<?php
}
?>
</ul>
<?php
$this->beginWidget('bootstrap.widgets.BsPanel');
?>
示例3: foreach
?>
</a>
</div>
</div>
</div>
</div>
<?php
}
}
?>
</div>
<div class="tab-pane fade" id="for-lawyer" >
<?php
$lawyerMenus = Menu::getMenus(Validation::getAccessType(0), "Top Lawyer");
if (count($lawyerMenus)) {
foreach ($lawyerMenus as $key => $data) {
?>
<div class="col-sm-3">
<div class="lawyer-image-wrapper">
<div class="single-lawyer">
<div class="lawyerinfo text-center">
<img alt="<?php
echo $data["name"];
?>
" rel="<?php
echo $data["name"];
?>
logo" name="<?php
echo $data["name"];
示例4: foreach
<div class="container">
<div class="row">
<?php
include 'sitebar.php';
?>
<div class="col-sm-9 padding-right">
<div class="category-tab shop-details-tab"><!--category-tab-->
<div class="col-sm-12">
<ul class="nav nav-tabs">
<li class="active"><a href="#reviews" data-toggle="tab" align="center">LPO Traning</a></li>
</ul>
</div>
<table style="width:100%;">
<tr>
<?php
$lawyerMenus = Menu::getMenus(Validation::getAccessType(0), "LPO Training");
if (count($lawyerMenus)) {
foreach ($lawyerMenus as $key => $data) {
?>
<td><a href="<?php
echo $data["url"];
?>
"><img src="<?php
echo MENU_IMG_URL . "/" . $data['image'];
?>
" alt="disclaimer" width="80" height="80"><br/><br/><?php
echo $data["name"];
?>
</a> </td>
<?php
}
示例5: home
public function home()
{
if (Session::read("access_type")) {
$access_id = Session::read("access_type");
} else {
$access_id = 0;
}
$access_type = Validation::getAccessType($access_id);
$category_name = $access_type;
return Menu::getMenus($access_type, $category_name);
}
示例6: echo
echo ADMIN_URL;
?>
/menu_manager/DB.php?FLAG=DELSELECT">
<table class="table table-striped table-bordered table-hover" id="sample_1">
<thead>
<tr>
<th class="table-checkbox"><input type="checkbox" class="group-checkable" data-set="#sample_1 .checkboxes"/></th>
<th>Menu Group Name</th>
<th>Order</th>
<th>Sub Menu</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
$results = Menu::getMenus();
if (count($results) > 0) {
for ($index = 0; $index < count($results); $index++) {
$rows = $results[$index];
?>
<tr class="<?php
echo ($index + 1) % 2 == 0 ? 'even' : 'odd';
?>
gradeX">
<td> <input name="delete[]" type="checkbox" id="delete[]" value="<?php
echo $rows['id'];
?>
" class="checkboxes" /> </td>
<td><?php
echo $rows['name'];
?>
示例7: array
$tpl->ACAO = "Incluir";
$listMenu = array();
if (isset($_REQUEST['idPerfil'])) {
$oPerfil->getById($oPerfil->md5_Decrypt($_REQUEST['idPerfil']));
$tpl->DESCRICAO = $oPerfil->descricao;
$tpl->ACAO = "Alterar";
$tpl->ID = $oPerfil->id;
$oAcesso = new acesso();
$acessos = $oAcesso->getRows(0, 999, array(), array("perfil" => " = " . $oPerfil->id));
foreach ($acessos as $acesso) {
array_push($listMenu, $acesso->menu->id);
}
}
//MONTAGEM DOS ACESSO DE MENU
$oMenu = new Menu();
$menus = $oMenu->getMenus();
foreach ($menus as $key => $menu) {
$tpl->DESC_MENU = $menu->descricao;
$tpl->ID_MENU = $menu->id;
if (count($menu->subMenus) > 0) {
foreach ($menu->subMenus as $key2 => $submenu) {
$tpl->DESC_SUBMENU = $submenu->descricao;
$tpl->ID_SUBMENU = $submenu->id;
if (array_search($submenu->id, $listMenu) !== false) {
$tpl->CHECKED_SUBMENU = 'checked="checked"';
}
$tpl->block("BLOCK_SUBMENU_PERFIL");
$tpl->clear("CHECKED_SUBMENU");
}
if (array_search($menu->id, $listMenu) !== false) {
$tpl->CHECKED_MENU = 'checked="checked"';