Q2:phpcms文章页如何加上一页下一页
首先:在show.php里"include template(phpcms, $template);"前直接添加以下代码就可以调用了
代码://<添加自定义代码>
$more_pre = $db->get_one("SELECT title,url FROM `".DB_PRE."content` WHERE `contentid`<$contentid and catid=$catid order by contentid desc limit 0,1");
$more_next = $db->get_one("SELECT title,url FROM `".DB_PRE."content` WHERE `contentid`>$contentid and catid=$catid order by contentid asc limit 0,1");
//添加自定义代码>
在模板文件中(show.html)调用方式
代码:
- 上一篇: {$more_pre[title]}
- 下一篇: {$more_next[title]}
这是2008的。 v9和这个同理,自己敲代码。
Q3:dedecms文章页的首页、末页、上一页、下一页的调用标签。谢啦哦
默认模版中有,自己找
Q4:phpcms文章页如何显示上一页下一页
phpcms文章页要显示上一页下一页效果并不难,下面的代码大家不妨参考下,或许有所帮助
本文主要分享了phpcms文章页显示上一页下一页的代码如下:
复制代码代码如下:
{getsql="select * from phpcms_content where contentid>$contentid andcatid=$catid order by contentid" rows="1"}
{get sql="select * fromphpcms_content where contentid<$contentid and catid=$catid order bycontentid desc" rows="1"}
W∴ww.bAzHIshi.coM