• Downloading from our site will require you to have a paid membership. Upgrade to a Premium Membership from 10$ a month today!

    Dont forget read our Rules! Also anyone caught Sharing this content will be banned. By using this site you are agreeing to our rules so read them. Saying I did not know is simply not an excuse! You have been warned.

Share mod bộ đếm lượt truy cập đơn giản cho php

Admin

Well-Known Member
Staff member
Administrator
Code tạo bộ đếm lượt truy cập đơn giản cho code viết bằng php. Ai biết rồi đừng chém mình nhé!
B1: Tạo 1 file mới với tên count.php mở file count.php dán đoạn mã này vào:
PHP:
<?php
$counter = "./counter.txt";
$today = getdate();
$month = $today[month];
$mday = $today[mday];
$year = $today[year];
$current_date = $mday . $month . $year;
// Log visit;
$fp = fopen($counter, "a");
$line = $REMOTE_ADDR . "|" . $mday . $month . $year . "\n";
$size = strlen($line);
fputs($fp, $line, $size);
fclose($fp);
$contents = file($counter);
$total_hits = sizeof($contents);
$total_hosts = array();
for ($i=0;$i<sizeof($contents);$i++) {
$entry = explode("|", $contents[$i]);
array_push($total_hosts, $entry[0]);
}
$total_hosts_size = sizeof(array_unique($total_hosts));
$daily_hits = array();
for ($i=0;$i<sizeof($contents);$i++) {
$entry = explode("|", $contents[$i]);
if ($current_date == chop($entry[1])) {
array_push($daily_hits, $entry[0]);
}
}
$daily_hits_size = sizeof($daily_hits);
$daily_hosts = array();
for ($i=0;$i<sizeof($contents);$i++) {
$entry = explode("|", $contents[$i]);
if ($current_date == chop($entry[1])) {
array_push($daily_hosts, $entry[0]);
}
}
$daily_hosts_size = sizeof(array_unique($daily_hosts));
?>
B2: Mở file cần chèn bộ đếm tìm đoạn
PHP:
<?php
chèn dưới
PHP:
include("count.php");
B3: Tìm tới nơi cần đặt bộ thêm vào
PHP:
echo "Today: ".$daily_hits_size." | Total: ".$total_hits."";
Xong
 

Facebook Comments

Similar threads
Thread starter Title Forum Replies Date
Admin Share mod xóa toàn bộ bài viết của thành viên spam (nhiều hơn 50 bài viết) Add-ons 0
Admin Mod xoá toàn bộ bài viết thành viên spam vbb3.x.x, vbb4.x.x Add-ons 4
Admin [OzzModz] Display Visitor Name ( [you] Mod) Xenforo 0
hellonhe forummmo.com cần tuyển admin, mod và các đại ca cntt Tin tức, sự kiện thường ngày 0
ginbarca Xin source johncms mod full Johncms 0
Admin Not Your Average Adblock Detecting Mod (hide images in post) Add-ons 0
Admin Yilmaz - Image upload mod for vB5 Add-ons 0
Admin HTML5 Game Mod for ibProArcade Add-ons 0
Admin German translation for [OzzModz] Email Staff When New Post/Thread In Mod Queue Xenforo 0
Admin Share code wap upload mod full Mã nguồn wap 3
dammechiase Tải hack game township mới nhất miễn phí cho android – Mod Full Tiền không cần root máy Trò chơi 0
dammechiase Tải Hack Game Subway Surfers Mod full coin, key, Hoverboard cho android không cần root máy Trò chơi 0
dammechiase Dowload Mod Skin LoL Pro 2020 mới nhất Trò chơi 0
dammechiase Download Game GTA Vice City Full Mod Tiếng Việt – Cướp đường phố bản chuẩn Trò chơi 0
dammechiase Hack Game Game VALKYRIE CONNECT Mới Nhất / 神域召唤:魔法少女 v4.3.0 BILIBILI MENU MOD Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Fishing Hook Free Mới Nhất – Mod Full Tiền Game Lưỡi Câu Miễn Phí không cần root máy Trò chơi 0
dammechiase Hack Game Captain Tsubasa: Dream Team Mới Nhất v2.3.2 MENU MOD | WEEKEN ENEMY | FULL STAMINA Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Royal Garden Tales – Match 3 Puzzle Decoration Mới Nhất v0.9.0 MOD FREE GOLD Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Pet World – My animal shelter Mới Nhất v5.1 MOD Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Ice Crush Mới Nhất MOD unlimited coins Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Game Mighty Party: Heroes Clash Mới Nhất v1.26 ULTRA MOD | ALL IN ONE | MENU ON OFF MOD Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Marmok's Team Monster Crush Mới Nhất MOD many coins/diamonds Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Game LINE: GUNDAM WARS Mới Nhất v3.5.1 MOD ATTACK – DEFENSE – MENU MOD Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Last Day on Earth: Survival Mới Nhất MOD free craft t Miễn Phí Cho Android Trò chơi 0
dammechiase Hack Game Rules of Survival Mới Nhất Update 2019 Mobile Android – ROS Mod Update Trò chơi 0
dammechiase Hack Game Kingdom Rush Vengeance Mới Nhất Mod không giới hạn Trò chơi 0
dammechiase Hack Game Legend vs Zombies Mới Nhất MOD Không giới hạn Trò chơi 0
dammechiase Hack Game Alien War Mới Nhất mod kim cương (gems) – Game Spaceship Shooter cho Android Trò chơi 0
dammechiase Hack Dream League Soccer 2019 Mới Nhất -Hướng Dẫn Mod Đội Hình Việt Nam AFF CUP Buff Chỉ Số Dream League Soccer 2019 Trò chơi 0
dammechiase Hack Game Zing Speed Mobile Mới Nhất VNG Mod Mới Nhất Không Cần Root Máy Trò chơi 0
dammechiase hack Game Long Đồ Bá Nghiệp mới nhất Mod & Hack For Android Trò chơi 0
dammechiase hack Game Lệnh Giang Hồ Mới Nhất 2019– Hack Game Free Vip 7 Mod & Hack For Android Trò chơi 0
dammechiase hack game gta 5 cướp đường phố Mod GTA 5 bá đạo, đỉnh nhất game Cướp đường phố Trò chơi 0
dammechiase Hack Mod Game Commander Battle Miễn Phí Cho Android mới nhất Trò chơi 0
dammechiase Hack Game Mini Golf King Free hack mod Mini Golf King Free cho Android Trò chơi 0
dammechiase Tải Hack Free Fire Mới Nhất – MOD v7 AimBot,99,99% No Recoil, Tăng Dame cập nhật mới nhất Trò chơi 0
dammechiase Tải game Half Life - CS 1.1 mod map, mod súng cực đẹp Trò chơi 0
dammechiase tải game *** Sacred Sword Princesses 18+ Hack Sacred Sword Princesses mới nhất Mod Full God Mode X10 Dmg Trò chơi 0
dammechiase Tải hack Game Liên Quân Võ Lâm Mobile mới nhất Hack Mod Full Vàng Full Coins Full tiền money mới nhất Trò chơi 0
dammechiase Tải Hack Dream League Soccer bản mới nhất 2019 hack Mod Full Tiền Và Đội Hình U23 Việt Nam Trò chơi 0
dammechiase Tải Hack Sniper 3D Assassin – Mod Game Sát Thủ Bắn Tỉa Hack Full Tiền Cho Android Trò chơi 0
dammechiase Tải hack game township mới nhất miễn phí cho android – Mod Full Tiền không cần root máy Trò chơi 0
dammechiase Hack Subway Surfers bản mới nhất Android Game – Mod Hack Full Coin Key Hoverboard No Root Trò chơi 0
dammechiase Tải Hack Zombie Tsunami mới nhất Mod full kim cương Android – Hack full vàng không cần Root máy Trò chơi 0
dammechiase Tải Hack Game Samurai 2 Vengeance mới nhất Mod Full Coin Tiền Vàng – Android Hack full mod no Root Trò chơi 0
dammechiase Hướng dẫn hack game truy kích mới nhất hack Mod Truy Kích Mobile Không Giật, Wall, Aimbot Trò chơi 0
hunglata Android cần giúp mod file apk Android, iOS 0
khanhsak3r Help Cần hướng dẫn mod màu nick thành viên cho johncms Johncms 7
Admin Hướng dẫn fix lỗi /includes/vfchh/php/vfc_hide_core.php on line 163 mod vFCoders - Hide Hack v4 Vbb tutorial 0
khanhsak3r Xin Mod đăng nhập bằng facebook cho johncms Johncms 4

Similar threads

New posts New threads New resources

Back
Top