在織夢(mèng)dedecms文章內(nèi)容頁(yè)中都會(huì)用上一篇下一篇來(lái)提高網(wǎng)站文章之間的相關(guān)性,這樣也有利于網(wǎng)站的收錄,但是如果想要更改這里面的一些東西還要注意修改。
找到include/arc.archives.class.php
查找
$this->PreNext['pre'] = "上一篇:<a href='$mlink'>{$preRow['title']}</a> ";
修改為
$this->PreNext['pre'] = "<span class='prev'><a href='$mlink' rel='prev'>{$preRow['title']}</a></span>";
查找
$this->PreNext['pre'] = "上一篇:沒(méi)有了";
修改為
$this->PreNext['pre'] = "<span class='prev'><a href='http://www.織夢(mèng)58dede58.com'>你想要的文字</a></span> ";
查找
$this->PreNext['next'] = "下一篇:<a href='$mlink'>{$nextRow['title']}</a> ";
修改為
$this->PreNext['next'] = "<span class='next'><a href='$mlink' rel='next'>{$nextRow['title']}</a></span> ";
查找
$this->PreNext['next'] = "下一篇:沒(méi)有了 ";
修改為
$this->PreNext['next'] = "<span class='next'><a href='http://www.織夢(mèng)58dede58.com'>你想要的文字</a></span>";
文章模板里調(diào)用代碼
<div class="wz-pagelast">{dede:prenext get='pre'/} {dede:prenext get='next'/} </div>
CSS代碼
/*上下篇*/
.wz-pagelast .prev a {
background: url("../images/icons.gif") no-repeat scroll 0 -224px transparent;
float: left;
height: 16px;
line-height: 16px;
padding-left: 22px;
}
.wz-pagelast .next a {
background: url("../images/icons.gif") no-repeat scroll 100% -240px transparent;
float: right;
height: 16px;
line-height: 16px;
padding-right: 22px;
}