久久机这里只有精品,国产69精品一区二区亚洲孕妇,91精品国产综合久久婷婷香蕉,午夜久久久久久电影

最新活動(dòng):電腦PC端+手機(jī)端+微網(wǎng)站+自適應(yīng)網(wǎng)頁多模板選擇-建站388元起價(jià)!!!
當(dāng)前位置:主頁 > 網(wǎng)站建設(shè) > dede5.7 動(dòng)態(tài)導(dǎo)航下拉菜單的實(shí)現(xiàn)代碼,織夢(mèng)技術(shù)

dede5.7 動(dòng)態(tài)導(dǎo)航下拉菜單的實(shí)現(xiàn)代碼,織夢(mèng)技術(shù)

時(shí)間:2023-07-20 13:07:20 閱讀: 文章分類: 網(wǎng)站建設(shè) 作者: dede技術(shù)員

導(dǎo)讀:織夢(mèng)技術(shù)織夢(mèng)技術(shù)織夢(mèng)模板網(wǎng)點(diǎn)評(píng) :dede5.7 動(dòng)態(tài)導(dǎo)航下拉菜單的實(shí)現(xiàn)代碼,需要的朋友可以參考一下 1.修改 include下面taglib文件夾里的channel.lib.織夢(mèng)模板免費(fèi)下裁dede模板堂。

織夢(mèng)模板免費(fèi)下裁dede模板堂織夢(mèng)模板網(wǎng)點(diǎn)評(píng):dede5.7 動(dòng)態(tài)導(dǎo)航下拉菜單的實(shí)現(xiàn)代碼,需要的朋友可以參考一下     1.修改 include下面taglib文件夾里的channel.lib.php文件 替換成我的 代碼如下: <?php function lib_channel(&$ctag,&$refObj) { global $_sys_globals,$envs,$ds夢(mèng)織模板ql; $attlist = "typeid|0,reid|0,row|100,col|1,type|son,currentstyle|"; FillAttsDefault($ctag->CAttribute->Items,$attlist); extract($ctag->CAttribute->Items, EXTR_SKIP); $innertext = $ctag->GetInnerText(); if(empty($typeid) && $envs['typeid']!=0) { $typeid = $envs['typeid']; $reid = $envs['reid']; }else{ $reid=0; }  if($type==''||$type=='sun') $type="son"; if($innertext=='') $innertext = GetSysTemplets("channel_list.htm"); if($reid==0 && $typeid>0) { $dbrow = $dsql->GetOne("Select reid From <a href="mailto:`dede_arctype">`dede_arctype</a>` where id='$typeid' "); if(is_array($dbrow)) $reid = $dbrow['reid']; } $likeType = ''; if($type=='top') { $sql = "Select id,typename,typedir,isdefault,ispart,defaultname,namerule2,description From <a href="mailto:`dede_arctype">`dede_arctype</a>` where reid=0 And ishidden<>1 order by sortrank asc limit 0,$row"; } else if($ty織夢(mèng)模板免費(fèi)pe=="son") { //if($_sys_globals['typeid']>0) $typeid = $_sys_globals['typeid']; if($typeid==0) { return ''; } $sql = "Select id,typename,typedir,isdefault,ispart,defaultname,namerule2,description From <a href="mailto:`dede_arctype">`dede_arctype</a>` where reid='$typeid' And ishidden<>1 order by sortrank asc limit 0,$row"; } else if($type=="self") { if($reid==0) { return ''; } $sql = "Select id,typename,typedir,isdefault,ispart,defaultname,namerule2,description From <a href="mailto:`dede_arctype">`dede_arctype</a>` where reid='$reid' And ishidden<>1 order by sortrank asc limit 0,$row"; } //And id<>'$typeid' $dtp2 = new DedeTagParse(); $dtp2->SetNameSpace("field","[","]"); $dtp2->LoadSource($innertext); $dsql2 = clone $dsql; $dsql->SetQuery($sql); $dsql->Execute(); $line = $row; $GLOBALS['autoindex'] = 0; for($i=0;$i < $line;$i++) { if($col>1) $likeType .= "<dl>\r\n"; for($j=0;$j<$col;$j++) { if($col>1) $likeType .= "<dd>\r\n"; if($row=$dsql->GetArray()) { if($type=='self' && $row['id']==$typeid) //處理同級(jí)欄目中,當(dāng)前欄目的樣式 { if($currentstyle!='') { $linkOkstr = $currentstyle; $row['typelink'] = GetOneTypeUrlA($row); $linkOkstr = str_replace("~typelink~",$row['typelink'],$linkOkstr); $linkOkstr = str_replace("~typename~",$row['typename'],$linkOkstr); $likeType .= $linkOkstr; } }else { $row['typelink'] = $row['typeurl'] = GetOneTypeUrlA($row); if(is_array($dtp2->CTags)) { foreach($dtp2->CTags as $tagid=>$ctag){ if(isset($row[$ctag->GetName()])) { $dtp2->Assign($tagid,$row[$ctag->GetName()]); } elseif (preg_match('/^sonchannel[0-9]*$/',$ctag->GetName())) { $dtp2->Assign($tagid,lib_channel_son($ctag,$row['id'],$dsql2)); } } } $likeType .= $dtp2->GetResult(); } } if($col>1) $likeType .= "</dd>\r\n"; $GLOBALS['autoindex']++; }//Loop Col if($col>1) { $i += $col - 1; $likeType .= " </dl>\r\n"; } }//Loop for $i reset($dsql2); $dsql->FreeResult(); return $likeType; } function lib_channel_son($ctag,$typeid = 0,$dsql2) { $attlist = "row|100,col|1,currentstyle|"; FillAttsDefault($ctag->CAttribute->Items,$attlist); extract($ctag->CAttribute->Items, EXTR_SKIP); $innertext = $ctag->GetInnerText(); $dsql3 = clone $dsql2; $likeType = ''; //if($_sys_globals['typeid']>0) $typeid = $_sys_globals['typeid']; if($typeid==0) { return ''; } $sql = "Select id,typename,typedir,isdefault,ispart,defaultname,namerule2,description From <a href="mailto:`dede_arctype">`dede_arctype</a>` where reid='$typeid' And ishidden<>1 order by sortrank asc limit 0,$row"; //And id<>'$typeid' $dtp2 = new DedeTagParse(); $dtp2->SetNameSpace("field","[","]"); $dtp2->LoadSource($innertext); $dsql2->SetQuery($sql); $dsql2->Execute(); $line = $row; for($i=0;$i < $line;$i++) { if($col>1) $likeType .= "<dl>\r\n"; for($j=0;$j<$col;$j++) { if($col>1) $likeType .= "<dd>\r\n"; if($row=$dsql2->GetArray()) { $row['typelink'] = $row['typeurl'] = GetOneTypeUrlA($row); if(is_array($dtp2->CTags)) { foreach($dtp2->CTags as $tagid=>$ctag){ if(isset($row[$ctag->GetName()])) { $dtp2->Assign($tagid,$row[$ctag->GetName()]); } elseif (preg_match('/^sonchannel[0-9]*$/',$ctag->GetName())) { $dtp2->Assign($tagid,lib_channel_son($ctag,$row['id'],$dsql3)); } } } $likeType .= $dtp2->GetResult(); } if($col>1) $likeType .= "</dd>\r\n"; }//Loop Col if($col>1) { $i += $col - 1; $likeType .= " </dl>\r\n"; } }//Loop for $i reset($dsql3); $dsql2->FreeResult(); return $likeType; } ?> 2.調(diào)用 這是我調(diào)用的代碼  代碼如下: {dede:channel typeid='1'} <li> <a class="" href="[field:typeurl/]" title="">[field:typename/] <img src="***.gif" /></a> <div class="sub"> <ul>  [field:sonchannel0]<li><a href="[field:typeurl/]">[field:typename/]</a></li>[/field:sonchannel0] </ul> </div> </li> {/dede:channel}相關(guān)織夢(mèng)模板免費(fèi)下裁dede模板堂。

關(guān)鍵詞標(biāo)簽: 織夢(mèng) 代碼 菜單

聲明: 本文由我的SEOUC技術(shù)文章主頁發(fā)布于:2023-07-20 ,文章dede5.7 動(dòng)態(tài)導(dǎo)航下拉菜單的實(shí)現(xiàn)代碼,織夢(mèng)技術(shù)主要講述菜單,代碼,織夢(mèng)網(wǎng)站建設(shè)源碼以及服務(wù)器配置搭建相關(guān)技術(shù)文章。轉(zhuǎn)載請(qǐng)保留鏈接: http://www.bifwcx.com/article/web_32271.html

我的IDC 網(wǎng)站建設(shè)技術(shù)SEOUC.COM
專注網(wǎng)站建設(shè),SEO優(yōu)化,小程序設(shè)計(jì)制作搭建開發(fā)定制網(wǎng)站等,數(shù)千家網(wǎng)站定制開發(fā)案例,網(wǎng)站推廣技術(shù)服務(wù)。
  • 5000+合作客服
  • 8年從業(yè)經(jīng)驗(yàn)
  • 150+覆蓋行業(yè)
  • 最新熱門源碼技術(shù)文章

    主站蜘蛛池模板: 陵川县| 廊坊市| 和政县| 舟山市| 眉山市| 同德县| 屏东县| 北川| 凤冈县| 额敏县| 屯昌县| 吉木萨尔县| 高尔夫| 株洲市| 淳安县| 海盐县| 平湖市| 澳门| 扬中市| 开封县| 侯马市| 铁岭市| 辉县市| 孟州市| 高唐县| 鹤庆县| 会东县| 射洪县| 扬州市| 琼中| 朝阳县| 增城市| 晋州市| 揭西县| 肃宁县| 靖远县| 晋江市| 新田县| 民权县| 大荔县| 靖安县|