列表页第一页显示栏目内容(帝国cms7.5栏目修改时,有一个单页内容)+文章列表,后面分页就只显示文章列表。
实现方法如下:
一,自定义一个模板标签[!–class.context–],放到列表模板适当的位置。
二,找到文件e/class/functions.php
三,找到函数function ListHtml,找到$string=str_replace(‘[!–list.pageno–],在下面新增以下代码:
//首页
if($pagenum==1)
{
	//子栏目、大栏目
	if ($enews==0 || $enews==3) {
		$classContext=$empire->fetch1("select eclasspagetext from {$dbtbpre}enewsclassadd where classid='$classid'");
		$string=str_replace('[!--class.context--]',$classContext['eclasspagetext'],$string);
	}
	//标题分类
	else if ($enews==5) {
		$classContext=$empire->fetch1("select intro from {$dbtbpre}enewsinfotype where typeid='$classid'");
		$string=str_replace('[!--class.context--]',$classContext['intro'],$string);
	}
	else{
		$string=str_replace('[!--class.context--]','',$string);
	}
}
else
{
	$string=str_replace('[!--class.context--]','',$string);
}