VIP福利
主页 > 建站问题 > 标签调用 > dedecms arclist列表循环调用顶级栏目名称方法

dedecms arclist列表循环调用顶级栏目名称方法

添加到include/extend.func.php里 function gettopname($aid){ global $dsql; $sql = SELECT tt.typename,tt.typedir from arctiny as a join arctype as t on a.typeid = t.id join arctype as tt on t.topid=tt.id where a.id = $aid ; $row = $dsql-Ge […]



添加到include/extend.func.php里
function gettopname($aid){
 global  $dsql; 
$sql = "SELECT tt.typename,tt.typedir from arctiny as a join arctype as t on a.typeid = t.id join arctype as tt on t.topid=tt.id where a.id = $aid" ; 
$row = $dsql->GetOne($sql);
$typename = $row['typename'];
$typedir = $row['typedir'];
$bodytag = str_replace("{cmspath}",$url,$typedir);
  return $lit_imglist = $typename;
}
2.arclist调用标签(显示顶级栏目名称) 
[field:id function='gettopname(@me)'/]

说点什么吧
  • 全部评论(0
    还没有评论,快来抢沙发吧!