Spaces:
Sleeping
Sleeping
Create templates/index.html
Browse files- templates/index.html +37 -0
templates/index.html
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html>
|
| 3 |
+
<head>
|
| 4 |
+
<title>IP & Location Tracker</title>
|
| 5 |
+
<style>
|
| 6 |
+
body { font-family: Arial, sans-serif; max-width: 800px; margin: 0 auto; padding: 20px; }
|
| 7 |
+
.info-box { background: #f5f5f5; padding: 20px; border-radius: 5px; margin-bottom: 20px; }
|
| 8 |
+
table { width: 100%; border-collapse: collapse; }
|
| 9 |
+
th, td { padding: 8px; text-align: left; border-bottom: 1px solid #ddd; }
|
| 10 |
+
th { background-color: #f2f2f2; }
|
| 11 |
+
.error { color: red; }
|
| 12 |
+
</style>
|
| 13 |
+
</head>
|
| 14 |
+
<body>
|
| 15 |
+
<h1>Welcome to IP & Location Tracker</h1>
|
| 16 |
+
|
| 17 |
+
<div class="info-box">
|
| 18 |
+
<h2>Your Connection Information</h2>
|
| 19 |
+
{% if error %}
|
| 20 |
+
<p class="error">Error: {{ error }}</p>
|
| 21 |
+
{% else %}
|
| 22 |
+
<p><strong>IP Address:</strong> {{ ip }}</p>
|
| 23 |
+
<p><strong>Location:</strong>
|
| 24 |
+
{{ location.city }}, {{ location.regionName }}, {{ location.country }}
|
| 25 |
+
</p>
|
| 26 |
+
<p><strong>Coordinates:</strong> {{ location.lat }}, {{ location.lon }}</p>
|
| 27 |
+
<p><strong>ISP:</strong> {{ location.isp }}</p>
|
| 28 |
+
<p><strong>Timezone:</strong> {{ location.timezone }}</p>
|
| 29 |
+
{% if location.proxy %}
|
| 30 |
+
<p class="warning">⚠️ This IP appears to be using a proxy/VPN</p>
|
| 31 |
+
{% endif %}
|
| 32 |
+
{% endif %}
|
| 33 |
+
</div>
|
| 34 |
+
|
| 35 |
+
<p><a href="/visitors">View visitor logs</a> (admin only)</p>
|
| 36 |
+
</body>
|
| 37 |
+
</html>
|