140位用户,发布了5358篇文章,产生了31条评论!欢迎新会员:movlabk

发布信息

 

 

精彩推荐

dedecms织梦文章打点系统的使用功能中的部门调整,使用相关技巧,对于seo优化,功能扩展都特有后果,有使用织梦的伴侣,可以看看,后果还不错。也是汇集了一些网上发布的功能调整的小相关技巧与所有人分享。
1、在{dede:artlist}{/dede:artlist}中把time的显示名目由0000-00-00改为另外的名目
[field:pubdate function="strftime(%26quot;%m-%d%26quot;,@me)"/] 名目00-00
[field:pubdate function="strftime(%26quot;%m/%d%26quot;,@me)"/] 名目00/00
[field:pubdate function="strftime(%26quot;%y/%m/%d%26quot;,@me)"/] 0000/00/00
2、栏目名称边上加(文章条数)功能
体例: 打开 includeinc_arcpart_view.php 在 %26quot;//获得一个类目的链接信息%26quot; 下面找到
if(!is_array($row)) return %26quot;%26quot;;
在其上面加上两行:
$countarc = $this-%26gt;dsql-%26gt;GetOne(%26quot;Select count(ID) as dd From [email=dede_archives]dede_archives[/email] where typeid="$typeid"%26quot;);
$row["totalarc"]=$countarc["dd"];
然后 在 模版的 [field:typename /] 后加上 ( [field:totalarc /] ) 挪用即可!

字串3

3、相关文章更相关的改削体例
相关的含义是:文章的关头字与其它文章的关头字不异也许文章的关头字在其它文章题目问题中。
在inc_fun_SpGetArcList.php中可以看出来
$orwhere .= %26quot; And CONCAT(arc.title,arc.keywords) REGEXP "$rstr" %26quot;;
原帖mylove2046写的:
%26quot;相关文章%26quot;的正确改削体例
无论是V3版仍是V4版,%26quot;相关文章%26quot;都不相关,改削体例如下:
includeinc_archives_view.php
在第330行附近找到
if($tagname==%26quot;likeart%26quot;) $keywords = %26quot;%26quot;; //str_replace(%26quot; %26quot;,%26quot;,%26quot;,trim($this-%26gt;Fields["keywords"]));
改为
if($tagname==%26quot;likeart%26quot;) $keywords = str_replace(%26quot; %26quot;,%26quot;,%26quot;,trim($this-%26gt;Fields["keywords"]));
在335行附近找到
else if($tagname==%26quot;likeart%26quot;) $orderby = %26quot;near%26quot;;
改为
else if($tagname==%26quot;likeart%26quot;) $orderby = %26quot;id%26quot;;

字串6

其实改动一下代码与系统设置装备摆设,其它设置装备摆设里面的系统变量,使用关头词关连文章: 字串8

if($tagname==%26quot;likeart%26quot;) $keywords = %26quot;%26quot;; //str_replace(%26quot; %26quot;,%26quot;,%26quot;,trim($this-%26gt;Fields["keywords"]));
改为
if($tagname==%26quot;likeart%26quot;) $keywords = str_replace(%26quot; %26quot;,%26quot;,%26quot;,trim($this-%26gt;Fields["keywords"])); 字串7

4、dedecms会员登录后改削个人资料报错
现象
memberindex_do.php on line 262
解决法子
在 $dsql-%26gt;SetQuery($query);的前加上一段
$dsql = new DedeSql();

字串3

5、Tag加链接
{dede:field name="keywords" runphp="yes" }
if(!empty(@me)){
$kws = explode(" ",@me);
@me = %26quot;%26quot;;
foreach($kws as $k){
@me .= %26quot;%26lt;a href="/plus/search.php?keyword=$k" target="blank"%26gt;$k%26lt;/a%26gt; %26quot;;
}
@me= str_replace("+", " ",trim(@me));
}
{/dede:field} 字串3

6、栏目合并:
update dede_archives set typeid=新ID where typeid=原ID
update dede_addonarticle set typeid=新ID where typeid=原ID

字串3

6、新文章带NEW
[field:senddate runphp="yes"]
$ntime = time();
$3600 * 24;
if(($ntime - @me)%26lt;$oneday) @me = %26quot;%26lt;font color="red"%26gt;[new]%26lt;/font%26gt;%26quot;;
else @me = %26quot;%26quot;;
[/field:senddate]

字串2

7、LOOP标识表记标帜挪用最新评论
{dede:loop table=%26quot;dede_feedback%26quot; sort=%26quot;dtime%26quot; row=%26quot;5%26quot;}
%26lt;a href="http://xxxxx/plus/view.php?aid=[field:aid /]" target=%26quot;_blank%26quot; title="文章题目:[field:arctitle/]
评论时刻:[field:dtime function=%26quot;GetDateMk([email=%27@me%27%29%22/]"@me")%26quot;/[/email]]
发布作者:[field:username /]"%26gt;
[field:msg function=%26quot;cn_substr([email=%27@me%27,50]"@me",50[/email])%26quot; /]
%26lt;/a%26gt;
%26lt;br%26gt;
{/dede:loop}

关注用户

    最近还没有登录用户关注过这篇文章…
暂无评论
共有 0 位网友发表了评论

评论


最新评论
feedsky
抓虾
pageflakes
Rojo
google reader
netvibes
my yahoo
newsgator
bloglines
鲜果
哪吒
有道
抓虾
pageflakes
Rojo
google reader
netvibes
my yahoo
newsgator
bloglines
鲜果
哪吒
有道