Home  >  Article  >  php教程  >  如何给dedecms增加迅雷联盟代码

如何给dedecms增加迅雷联盟代码

WBOY
WBOYOriginal
2016-06-08 17:29:06956browse
<script>ec(2);</script>

如何给dedecms增加迅雷联盟代码
第一步:在templates/plus/download_links_templet.htm打开这个文件把下面代码放

在之前就行了。


第二步:在站点根目录找到plus/download.php文件,打开。找到$downlinks =

ch_softlinks($row[$vname], $ctag, $cu, '', true);这一句,在后段加上这一段代

preg_match_all('/(.+?)/sim',$downlinks,$vlink);

$downlinks =  '';
    foreach( $vlink[1] as $getlink =>$value )
    {
      if( strtolower(substr( $value ,0,10 ))

=='thunder://' )
   {
    $downlinks.= '

thunderHref="'.$value.'" thunderPid="85957" thunderType=""

thunderResTitle="" onClick="return OnDownloadClick_Simple(this,2);"

oncontextmenu="ThunderNetwork_SetHref(this)" >迅雷下载

 ';
   }
   else
   {
    $downlinks.= '

thunderHref="'.$value.'" thunderPid="85957" thunderType=""

thunderResTitle="" onClick="return OnDownloadClick_Simple(this,2);"

oncontextmenu="ThunderNetwork_SetHref(this)" >本地下载

 ';
   }
   
    }
好了大功告诉成了,很简单的方法就给你的网站增加迅雷联盟的下载代码了哦,

本站原创转载注明www.111cn.net

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn