bodytop.php
公共顶部
节点表模型类
信息表模型类
<header class="header"> <div class="am-fr"> <!--注意,首页与其它页面就这里有点不同,如果是首页是下面的第一行,否则是第二行--> <a href="/_mfmb/0001/admin/" class="am-icon-user am-icon-sm"></a> <a href="javascript:history.go(-1)" class="am-icon-chevron-left am-icon-sm"></a> </div> <div class="am-fl"> <a href="javascript:;" class="am-icon-bars am-icon-sm" data-am-offcanvas="{target:'#nav_top'}"></a> </div> <div class="logo"> <a href="http://www.sznest.net/_mfmb/0001/index_wap.html"> <img src="/_backup/_upload/wap-logo.png" alt="" /></a> </div> <div class="clear"></div> </header> <div class="nav am-offcanvas" id="nav_top"> <div class="am-offcanvas-bar"> <ul id="collapase-nav"> <li class="am-panel"> <a href="http://www.sznest.net/_mfmb/0001/index_wap.html" title="首页">首页</a> </li> <li class="am-panel"> <span class="am-icon-angle-right" data-am-collapse="{parent:'#collapase-nav', target:'#nav_2'}"></span> <a href="http://www.sznest.net/_mfmb/0001/gywm/index_wap.html" title="关于我们">关于我们</a> <ul class="am-collapse" id="nav_2"> <li><a href="http://www.sznest.net/_mfmb/0001/gywm/index_wap.html" title="公司简介">公司简介</a></li> <li class = 'lastli'><a href="http://www.sznest.net/_mfmb/0001/gywm/qywh_wap.html" title="企业文化">企业文化</a></li> </ul> </li> <li class="am-panel"> <span class="am-icon-angle-right" data-am-collapse="{parent:'#collapase-nav', target:'#nav_3'}"></span> <a href="http://www.sznest.net/_mfmb/0001/xwzx/index_wap.html" title="新闻中心">新闻中心</a> <ul class="am-collapse" id="nav_3"> <li><a href="http://www.sznest.net/_mfmb/0001/xwzx/hyzx/index_wap.html" title="行业资迅">行业资迅</a></li> <li class = 'lastli'><a href="http://www.sznest.net/_mfmb/0001/xwzx/gsdt/index_wap.html" title="公司动态">公司动态</a></li> </ul> </li> <li class="am-panel"> <span class="am-icon-angle-right" data-am-collapse="{parent:'#collapase-nav', target:'#nav_4'}"></span> <a href="http://www.sznest.net/_mfmb/0001/cpzs/index_wap.html" title="产品展示">产品展示</a> <ul class="am-collapse" id="nav_4"> <li><a href="http://www.sznest.net/_mfmb/0001/cpzs/shjd/index_wap.html" title="生活家电">生活家电</a></li> <li class = 'lastli'><a href="http://www.sznest.net/_mfmb/0001/cpzs/znjd/index_wap.html" title="智能家电">智能家电</a></li> </ul> </li> <li class="am-panel"> <a href="http://www.sznest.net/_mfmb/0001/khal/index_wap.html" title="客户案例">客户案例</a> </li> <li class="am-panel lastli"> <a href="http://www.sznest.net/_mfmb/0001/lxwm/index_wap.html" title="联系我们">联系我们</a> </li> </ul> </div> </div>
<header class="header"> <div class="am-fr"> <?php if($rid == 1) { ?> <a href="<?=Web::getAdminStr()?>" class="am-icon-user am-icon-sm"></a> <?php }else{ ?> <a href="javascript:history.go(-1)" class="am-icon-chevron-left am-icon-sm"></a> <?php } ?> </div> <div class="am-fl"> <a href="javascript:;" class="am-icon-bars am-icon-sm" data-am-offcanvas="{target:'#nav_top'}"></a> </div> <div class="logo"> <a href="<?=Node::getSiteUrl(1)?>"> <img src="/_backup/_upload/wap-logo.png" alt="" /></a> </div> <div class="clear"></div> </header> <div class="nav am-offcanvas" id="nav_top"> <div class="am-offcanvas-bar"> <ul id="collapase-nav"> <?php //先取出根栏目的多行数据,即前台一级栏目 $nodetrs1 = Node::getTrs(0); //一级栏目循环开始 foreach ($nodetrs1 as $key1=>$nodetr1) { $nodetrs2 = Node::getTrs($nodetr1['id']); ?> <li class="am-panel<?php if($key1 == (count($nodetrs1)-1)) {echo " lastli";} ?>"> <?php if($nodetrs2) {?> <span class="am-icon-angle-right" data-am-collapse="{parent:'#collapase-nav', target:'#nav_<?=$key1+1?>'}"></span> <?php } ?> <a href="<?=Node::getSiteUrl($nodetr1['id'])?>" title="<?=$nodetr1['name']?>"><?=$nodetr1['name']?></a> <?php if($nodetrs2) {?> <ul class="am-collapse" id="nav_<?=$key1+1?>"> <?php foreach ($nodetrs2 as $key2=>$nodetr2) { ?> <li<?php if($key2 == (count($nodetrs2)-1)) {echo " class = 'lastli'";} ?>><a href="<?=Node::getSiteUrl($nodetr2['id'])?>" title="<?=$nodetr2['name']?>"><?=$nodetr2['name']?></a></li> <?php } ?> </ul> <?php } ?> </li> <?php } ?> </ul> </div> </div>