校园春色亚洲色图_亚洲视频分类_中文字幕精品一区二区精品_麻豆一区区三区四区产品精品蜜桃

主頁 > 網站建設 > 建站知識 > dede修改上/下一篇中的“沒有了”

dede修改上/下一篇中的“沒有了”

POST TIME:2021-05-23 01:26

在織夢默認的調用文章上/下一篇的時候如果下面為空的就會出現“沒有了”,但是如果想要出現這樣的文字,而是自己獨特設置的文字的話,就要在調用標簽上下點功夫了。

dedecms上一篇下一篇的調用標簽:

{dede:prenext get='pre'/}
{dede:prenext get='next'/}
dede修改上/下一篇中“沒有了”的方法

方法一:直接刪除“沒有了”

打開include/arc.archives.class.php
找到
$this->PreNext['pre'] = "上一篇:<a href='$mlink'>{$preRow['title']}</a> ";
$this->PreNext['pre'] = "上一篇:沒有了";
$this->PreNext['next'] = "下一篇:<a href='$mlink'>{$nextRow['title']}</a> ";
$this->PreNext['next'] = "下一篇:沒有了 ";
刪除“沒有了”即可

方法二:使用其他代碼替換“沒有了”

打開include/arc.archives.class.php
找到
$this->PreNext['pre'] = "上一篇:<a href='$mlink'>{$preRow['title']}</a> ";
$this->PreNext['pre'] = "上一篇:沒有了";
$this->PreNext['next'] = "下一篇:<a href='$mlink'>{$nextRow['title']}</a> ";
$this->PreNext['next'] = "下一篇:沒有了 ";
分別替換為以下幾行:
$this->PreNext['pre'] = "$mlink";
$this->PreNext['pre'] = "javascript:window.alert('上一篇:自己想要的話');";
$this->PreNext['next'] = "$mlink";
$this->PreNext['next'] = "javascript:window.alert('下一篇:自己想要的話');";

以上就是在文章內容模型中的修改方法了,如果想要在圖集中也不顯示“沒有了”,還要做一些修改:

打開include/arc.archives.class.php
找到
*$this->PreNext['preimg'] = "<a href='$mlink'><img src=\&;{$preRow['litpic']}\&; alt=\&;{$preRow['title']}\&;/></a> ";
$this->PreNext['preimg'] ="<img src=\&;/templets/default/images/nophoto.jpg\&; alt=\&;對不起,沒有上一圖集了!\&;/>";
$this->PreNext['nextimg'] = "<a href='$mlink'><img src=\&;{$nextRow['litpic']}\&; alt=\&;{$nextRow['title']}\&;/></a> ";
$this->PreNext['nextimg'] ="<a href='javascript:void(0)' alt=\&;\&;><img src=\&;/templets/default/images/nophoto.jpg\&; alt=\&;對不起,沒有下一圖集了!\&;/></a>";
分別替換為以下幾行:
$this->PreNext['preimg'] = "$mlink";
$this->PreNext['preimg'] ="javascript:window.alert('自己想要的話');";
$this->PreNext['nextimg'] = "$mlink";
$this->PreNext['nextimg'] ="javascript:window.alert('自己想要的話');";



收縮
  • 微信客服
  • 微信二維碼
  • 電話咨詢

  • 400-1100-266
主站蜘蛛池模板: 永德县| 尚志市| 安阳市| 桂阳县| 潼关县| 云浮市| 黑河市| 开化县| 偏关县| 云和县| 托克托县| 松江区| 自治县| 海淀区| 靖州| 彝良县| 崇礼县| 南昌县| 天祝| 丰宁| 南雄市| 沾化县| 额尔古纳市| 犍为县| 布尔津县| 望城县| 当雄县| 高阳县| 庆元县| 奉化市| 永善县| 大安市| 罗田县| 海丰县| 临西县| 广昌县| 潍坊市| 吉水县| 旌德县| 田林县| 新沂市|