|
织梦独立模型内容页输出上一篇下一篇,默认是不支持的,我们不修改程序内核文件,直接在模板里自由输出上一篇和下一篇文章
独立模型内容页输出上一篇下一篇 - 写法一
[*,
上一篇:
{dede:field.id runphp=yes}
global $dsql,$id,$aid,$typeid;
$myid = isset($id) ? $id : $aid;
$preR = $dsql->GetOne("Select id,channel From `dede_arctiny` where id-1 And typeid=$typeid order by id desc limit 1");
$arc = GetOneArchive($preR['id',);
@me = "[url={$arc[arcurl]},{$arc[title,}[/url]";
{/dede:field.id}
[*,
下一篇:
{dede:field.id runphp=yes}
global $dsql,$id,$aid,$typeid;
$myid = isset($id) ? $id : $aid;
$preR = $dsql->GetOne("Select id,channel From `dede_arctiny` where id>$myid And arcrank>-1 And typeid=$typeid order by id asc limit 1");
$arc = GetOneArchive($preR['id',);
@me = "[url={$arc[arcurl]},{$arc[title,}[/url]";
{/dede:field.id}
独立模型内容页输出上一篇下一篇 - 写法二
[*,
{dede:sql sql="SELECT * FROM dede_arctiny WHERE id-1 And typeid=~typeid~ order by id desc limit 1"}
上一篇:[url=,[field:id runphp=yes,$id=@me;$arc=GetOneArchive($id);@me=$arc['title',;[/field:id,[/url]
{/dede:sql}
[*,
{dede:sql sql="SELECT * FROM dede_arctiny WHERE id>~id~ And arcrank>-1 And typeid=~typeid~ order by id asc limit 1"}
下一篇:[url=,[field:id runphp=yes,$id=@me;$arc=GetOneArchive($id);@me=$arc['title',;[/field:id,[/url]
{/dede:sql} |
|