dedecms调用点击次数代码
点击:<script src="{dede:field name='phpurl'/}/count.php?view=yes&aid={dede:field name='id'/}&mid={dede:field name='mid'/}" type='text/javascript' language="javascript"></script>次
dedecms调用点击次数代码
点击:<script src="{dede:field name='phpurl'/}/count.php?view=yes&aid={dede:field name='id'/}&mid={dede:field name='mid'/}" type='text/javascript' language="javascript"></script>次
{dede:php}
$dsql = new DedeSql(false);
$typeid="82";
$sql="select a.id,a.title,t.typedir,c.body from #@__archives a,#@__arctype t ,#@__addonarticle c where a.typeid=t.id and a.id=c.aid and a.typeid=$typeid order by a.id desc limit 0,3";
$dsql->SetQuery($sql);
$dsql->Execute();
while($arc=$dsql->GetArray()){
$str.=' <li class="w"><a href="'.substr($arc['typedir'],9).'/'.$arc['id'].'.html" target="_blank">'.cn_substr($arc['title'],40).'...</a></li><li class="d">'.cn_substr(strip_tags($arc['body']),30,6).'..</li>';}
echo $str;
{/dede:php}