欢迎来访实搜网站库!

蓝色 学校 微商 大气 企业

phpcms v9全站排行榜,收藏量统计查询代码

时间:2015-07-23 15:21
phpcms v9全站排行榜,收藏量统计查询代码 {pc:get sql=quot;select *,count(*) as count from phpcms_favorite where adddate=DATE_SUB(CURDATE(),INTERVAL WEE

phpcms v9全站排行榜,收藏量统计查询代码

{pc:get sql="select *,count(*) as count from phpcms_favorite where adddate>=DATE_SUB(CURDATE(),INTERVAL WEEKDAY(CURDATE()) DAY) group by title order by count(*) desc" return="data" num="9"}
<ul>
{loop $data $key $val}
 <li><a href="{str_replace('/index.html','',$val[url])}" target="_blank" title="{$val[title]}">{$val[title]}</a> {$val[count]}</li>
{/loop}
</ul>
{/pc}

查看更多 phpcms教程 phpcms模板