Skip to content

Hotspot Login Page Template Mikrotik Page

button width: 100%; background: #ff6b35; color: white; border: none; padding: 14px; font-size: 18px; font-weight: bold; border-radius: 40px; cursor: pointer; transition: background 0.2s; margin-top: 10px;

<script> // Parse error from URL if redirected back with error function getQueryParam(param) let urlParams = new URLSearchParams(window.location.search); return urlParams.get(param);

.error-message background: #ffe6e5; color: #d32f2f; padding: 12px; border-radius: 8px; margin-bottom: 20px; text-align: center; font-size: 14px; display: none;

.brand h1 font-size: 28px; margin-bottom: 5px; Hotspot Login Page Template Mikrotik

.input-group label display: block; margin-bottom: 8px; font-weight: 600; color: #333; font-size: 14px;

.form-wrapper padding: 30px 25px;

.login-container background: white; border-radius: 16px; box-shadow: 0 20px 40px rgba(0,0,0,0.2); overflow: hidden; max-width: 450px; width: 100%; transition: all 0.3s ease; button width: 100%

button:hover background: #e55a2b;

.brand p opacity: 0.9; font-size: 14px;

<!-- IMPORTANT: The action URL must point to your hotspot gateway --> <form id="loginForm" action="$(link-login)" method="post" onsubmit="return validateForm()"> <!-- Required hidden fields for MikroTik --> <input type="hidden" name="dst" value="$(link-orig)"> <input type="hidden" name="popup" value="false"> transition: background 0.2s

<div class="input-group"> <label>Username</label> <input type="text" name="username" id="username" placeholder="Enter your username" required autofocus> </div> <div class="input-group"> <label>Password</label> <input type="password" name="password" id="password" placeholder="••••••" required> </div> <button type="submit">Connect Now</button> <div class="info-text"> By connecting, you agree to our <a href="#">Terms of Use</a> </div> </form> </div> <div class="footer"> © 2025 Your Business Name – High Speed WiFi </div> </div>

.input-group input:focus border-color: #ff6b35; outline: none; box-shadow: 0 0 0 3px rgba(255,107,53,0.1);

// Show error if 'err' parameter exists in URL window.onload = function() let err = getQueryParam('err'); if (err === 'true') document.getElementById('errorMsg').innerText = "Invalid username or password. Please try again."; document.getElementById('errorMsg').style.display = "block";

@media (max-width: 480px) .form-wrapper padding: 20px; </style> </head> <body> <div class="login-container"> <div class="brand"> <h1>Guest WiFi</h1> <p>Please login to access the internet</p> </div> <div class="form-wrapper"> <div id="errorMsg" class="error-message"></div>