Cara memasang Statistik DCMS dari database
Sekian lama vakum posting dikarenakan sibuk di x-sun.net!Kali ini saya ingin ngeshare bagaimana cara menampilkan statistik pengunjung untuk pengguna DCMS!
Langsung saja ke scriptnya!
<?Silahkan diedit lagi sesukanya!
echo "<div class='xxx'><center>Sundaylinkz Tracker by <span style='color:#000000;'><a href='http://x-sun.tk'></b></a></span></center></div>"; echo "<div class='acw apm' id='m_more_item'>"; $alluser=mysql_result(mysql_query("SELECT COUNT(*) FROM `user` WHERE `id`"),0);
echo "Total User : <span style='color:#ff0000;'><b>$alluser</b></span><br/>";
$satu=mysql_result(mysql_query("SELECT COUNT(*) FROM `user` WHERE `date_last` > ".(time()-600).""), 0);
$dua=mysql_result(mysql_query("SELECT COUNT(*) FROM `guests` WHERE `date_last` > ".(time()-600)." AND `pereh` > '0'"), 0);
$tiga= $satu + $dua;
echo "Pageview Now : <span style='color:#ff0000;'><b>$tiga</b></span> Online<br/>";
$view=mysql_result(mysql_query("SELECT COUNT(*) FROM `visit_today` WHERE `time`"),0);
echo "Pageview Today : <b><span style='color:#ff0000;'>$view</span></b> hits<br/>";
$kamari= mysql_result(mysql_query("SELECT (hit)
FROM `visit_everyday`
ORDER BY `time` DESC
LIMIT 1"), 0);
echo "Pageviews Yesterday : <span style='color:#ff0000;'><b>$kamari</b></span> hits<br/>";
$total=mysql_result(mysql_query("SELECT SUM(hit) FROM `visit_everyday`"),0);
$totalkabeh= $total+$view; echo "Pageview All Time : <b><span style='color:#ff0000;'>$totalkabeh</span></b> hits<br/></div>";
?>
Script diatas hanya contoh saja dan telah ditambah dengan total usernya!
Bila Anda malas menulis scriptnya, silahkan download file nya dibagian bawah posting ini! Include file tersebut ditempat yang di inginkan (contoh : include 'sys/inc/tracker.php'; )
Posted by: dian_sunday
diansunday
Updated at:
20.13