分享一个本站官网的一个统计sql代码:
<li><h3>{dede:sql sql="select count(mid) as c from dede_member "}本站共有:<strong><a href="https://www.91084.com/member/" target="_blank">[field:c /]</a></strong> 名会员入驻{/dede:sql} </h3></li><li><h3>{dede:sql sql="select count(*) as c from dede_archives where channel=17"}本站共有:<strong><a href="https://www.91084.com/free/" target="_blank">[field:c /]</a></strong> 个免费模板{/dede:sql} </h3></li><li><h3>{dede:sql sql="select count(*) as c from dede_archives where channel=19"}本站共有:<strong><a href="https://www.91084.com/svip/" target="_blank">[field:c /]</a></strong> 个会员模板{/dede:sql} </h3></li><li><h3>{dede:sql sql="select count(*) as c from dede_archives where channel=20"}本站共有:<strong><a href="https://www.91084.com/svp/" target="_blank">[field:c /]</a></strong> 个商业模板{/dede:sql} </h3></li><li><h3>{dede:sql sql="select count(*) as c from dede_archives where channel=18"}本站共有:<strong><a href="https://www.91084.com/chajian/" target="_blank">[field:c /]</a></strong> 个织梦插件{/dede:sql} </h3></li><li><h3>{dede:sql sql="select count(*) as c from dede_archives where channel=1"}本站共有:<strong><a href="https://www.91084.com/dedecms/" target="_blank">[field:c /]</a></strong> 篇织梦教程{/dede:sql} </h3></li><li><h3> {dede:sql sql="select sum(click) as c from dede_archives"}文章阅读:<strong><a href="https://www.91084.com/#">[field:c /]</a></strong> 次{/dede:sql} </h3></li>