帝国cms7.5列表页列表内容模板专题模板

专题模板

专题模板
列表内容模板(list.var) (*)
一定要勾选使用程序代码
代码如下:


$zhuanti=$empire->fetch1("select ztid,classid from {$dbtbpre}enewsztinfo where id = {$r['id']}");
if($zhuanti)
{
//专题名称
$ztname=$class_zr[$zhuanti['ztid']]['ztname'];
//专题链接
$ztlink=sys_ReturnBqZtname($zhuanti);
}
$listtemp='
     
  • [!--title--]

    '.$ztname.'
  • ';

    列表页获得专题名称和专题链接(列表内容模板(list.var) (*)中使用)

    
    $zhuanti=$empire->fetch1("select ztid,classid from {$dbtbpre}enewsztinfo where id = {$r['id']}");
    
    if($zhuanti)
    {$ztname=$class_zr[$zhuanti['ztid']]['ztname'];
    $ztlink=sys_ReturnBqZtname($zhuanti);}
    $listtemp=''.$ztname.'';

    内容页获得专题名称和专题链接

    
    [e:loop={'select ztid from phome_enewsztinfo where id='.$navinfor[id].'',1,24,0}]
    <a href="https://www.lovezheteng.com/">
    [/e:loop]

    内容页获得文章所属专题的最新文章列表

    
    [e:loop={'select ztid from phome_enewsztinfo where id='.$navinfor[id].'',1,24,0}]
    
    [/e:loop]
    [e:indexloop={$ztid1,5,1}] 
    <a href="">
    [/e:indexloop]

    专题信息数统计

    
    gettotal("select count(*) as total from {$dbtbpre}enewsztinfo where ztid=专题ID");echo $num;?>

    内容页获得文章所属标题分类的最新文章列表

    
    [e:loop={$navinfor[ttid],4,25,0}]
    <a href="">
    [/e:loop]

    标题分类信息数统计

    
    gettotal("select count(*) as total from {$dbtbpre}ecms_news where ttid=标题分类ID");echo $num;?>

    发表回复

    您的电子邮箱地址不会被公开。 必填项已用 * 标注