婷婷综合国产,91蜜桃婷婷狠狠久久综合9色 ,九九九九九精品,国产综合av

主頁 > 網站建設 > 建站知識 > 織夢DEDECMS中實現無覓相關文章功能

織夢DEDECMS中實現無覓相關文章功能

POST TIME:2018-09-02 13:16

無覓智能相關文章服務是無覓網面向網站用戶推出的一項智能云端服務,旨在提升網站相關文章的轉化率,幫助讀者發現網站的價值信息。它依托無覓精準的內容分析 和推薦算法,系統分析文章內容、標簽、用戶行為、時間等參數,實時生成關聯推薦結果,并在當前文章底部進行圖文展示,能夠給網站帶來快速的流量增長,也為 用戶提供流暢的閱讀體驗。

無覓相關文章默認展示樣式:

DEDECMS用戶可以通過在模板文件中添加代碼而定方式來使用無覓相關文章功能。以下代碼來自無覓官方網站。

1、編輯服務器上的/include/arc.archives.class.php文件,在$this->Fields = $this->dsql->GetOne($query);一行下插入以下代碼:

$this->Fields['arcurl'] = GetFileUrl(

$this->ArcID, $this->Fields["typeid"], $this->Fields["senddate"],

$this->Fields["title"], $this->Fields["ismake"],

$this->Fields["arcrank"], $this->TypeLink->TypeInfos['namerule'],

$this->TypeLink->TypeInfos['typedir'], $this->Fields["money"],

$this->Fields['filename'], $this->TypeLink->TypeInfos['moresite'],

$this->TypeLink->TypeInfos['siteurl'], $this->TypeLink->TypeInfos['sitepath']

);

 

2、繼續編輯該文件,找到if($this->ChannelUnit->ChannelInfos['addtable']!=”)一行,在其上插入以下代碼:

$this->Fields['wumiipic'] = strpos($this->Fields['litpic'], ‘/’) === 0 ? ($GLOBALS['cfg_basehost'] . $this->Fields['litpic']) : $this->Fields['litpic'];


3、進入后臺管理的“默認模板管理”頁面,分別在下列文件中找到對應代碼的位置:
article_article.htm,article_shop.htm,article_infos.htm以及V5.7版本中的所有隨機文章內容頁模板文件中,找到{dede:field.body/}
article_image.htm:
V5.3.1版本中找到<div class="picbox">對應的結束標簽</div>
V5.7版本中找到<div class="intro">對應的結束標簽</div>
article_soft.htm中找到<div class="intro">對應的結束標簽</div>
在以上位置之后添加以下代碼:

<div class="wumii-hook">

<input type="hidden" name="wurl" value="{dede:global.cfg_basehost/}{dede:field.arcurl/}" />

<input type="hidden" name="wtitle" value="{dede:field.title/}" />

<input type="hidden" name="wpic" value="{dede:field.wumiipic/}" />

</div>

<p style="display: none;">

{dede:tag}<a rel="tag">[field:tag /]</a>{/dede:tag}

</p>

<script>

var wumiiSitePrefix = "{dede:global.cfg_basehost/}{dede:global.cfg_indexurl/}/";

</script>

注:如果您的網站設置了“arclist內容啟用絕對網址”為YES,請將上述第二行代碼改為:

<input type="hidden" name="wurl" value="{dede:field.arcurl/}" />


4、在第3步修改的所有模板文件中找到文件末尾的</body>,在其前面添加以下代碼:

<script type="text/javascript">

var wumiiParams = "&num=5&mode=3&pf=DedeCMS_{dede:global.cfg_version/}";

</script>

<script type="text/javascript" id="wumiiRelatedItems" src="http://widget.wumii.com/ext/relatedItemsWidget.htm"></script>

5、在管理后臺更新文檔 HTML。




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

  • 400-1100-266
主站蜘蛛池模板: 土默特左旗| 天津市| 界首市| 大庆市| 浦东新区| 西畴县| 玛纳斯县| 阿荣旗| 甘泉县| 岐山县| 安仁县| 浪卡子县| 理塘县| 岳阳县| 亚东县| 蓬溪县| 永登县| 于田县| 桂阳县| 历史| 连山| 霍城县| 桐乡市| 郸城县| 同江市| 贵州省| 拉孜县| 耒阳市| 桃园市| 榆林市| 凤城市| 张家港市| 嘉定区| 临猗县| 秀山| 靖宇县| 九江县| 白玉县| 荣成市| 天峨县| 彝良县|