我们找到并打开/include/arc.archives.class.PHP文件,在里面找到如下代码:
function ReplaceKeyword($kw,&$body) { global $cfg_CMSpath; $maxkey = 5; $kws = explode(",",trim($kw)); //以分好为间隔符 $i=0; $karr = $kaarr = $GLOBALS['replaced'] = array(); //暂时屏蔽超链接 $body = preg_replace("#(sql->Getone("SELECT * FROM dede_keywords WHERE keyword='$k' AND rpurl<>'' "); if(is_array($myrow)) { $karr[] = $k; $GLOBALS['replaced'][$k] = 0; $kaarr[] = "href='{$myrow['rpurl']}'>找到后将其替换为如下代码:
function ReplaceKeyword($kw,&$body) { global $cfg_CMSpath,$dsql; $maxkey = 5; $kws = explode(",trim($kw)); //以分好为间隔符 $i=0; $karr = $kaarr = $GLOBALS['replaced'] = array(); //暂时屏蔽超链接 $body = preg_replace("/(query="SELECT * FROM dede_keywords WHERE rpurl<>'' and sta=1 ORDER BY length(keyword)desc"; $dsql->Setquery($query); $dsql->Execute(); while($row = $dsql->GetArray()) { $key = trim($row['keyword']); $key_url=trim($row['rpurl']); $karr[] = $key; $kaarr[] = "
替换完成后保存即可,然后重新生成整站 总结
以上是内存溢出为你收集整理的织梦关键词维护里面字数多的词优先字数少的词自动内链全部内容,希望文章能够帮你解决织梦关键词维护里面字数多的词优先字数少的词自动内链所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)