| Server IP : 104.21.21.239 / Your IP : 216.73.216.11 Web Server : Apache/2.4.68 (Amazon Linux) OpenSSL/3.5.5 System : Linux ip-172-31-69-123.ec2.internal 6.1.176-223.369.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Jul 24 13:34:27 UTC 2026 x86_64 User : ec2-user ( 1000) PHP Version : 8.4.23 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/banners/public_html/bway/pixel/ |
Upload File : |
<?php
/**
* Regional Bug Tracking Endpoint
* Replaces: regionalbug.cfm
*
* Tracks regional show views via advertiser pixel.
* Accepts id1–id6 params (show IDs > 1122051) and queues them
* as regionalstats events for the cron processor.
*/
require_once __DIR__ . '/config.php';
require_once __DIR__ . '/PixelResponse.php';
require_once __DIR__ . '/EventBuffer.php';
// --- Bot filter ---
$ua = $_SERVER['HTTP_USER_AGENT'] ?? '';
$bots = ['bot', 'spider', 'slurp', 'msie 6', 'addthis', 'ezautoinsert', 'crawler'];
$uaLower = strtolower($ua);
foreach ($bots as $bot) {
if (strpos($uaLower, $bot) !== false) {
PixelResponse::sendPixelAndFlush();
exit;
}
}
// --- Require advertiser param ---
$advertiser = $_GET['advertiser'] ?? null;
if ($advertiser === null) {
PixelResponse::sendPixelAndFlush();
exit;
}
// --- Send 1x1 GIF and close client connection ---
PixelResponse::sendPixelAndFlush();
// --- Everything below is invisible to the client ---
$today = date('Y-m-d H:i:s');
for ($i = 1; $i <= 6; $i++) {
$id = filter_input(INPUT_GET, 'id' . $i, FILTER_VALIDATE_INT);
if ($id !== null && $id !== false && $id > 1122051) {
EventBuffer::append('regionalstats', [
'showid' => $id,
'dater' => $today,
]);
}
}