Problem setting up html directory override

Hi everybody,

Im trying to set up an external login page and not having much luck.

Theres loads of information here on the forum but its confusing me.

I understand that I need to set up HTML Directory override first but whenever I set that it seems to be ignored.

Should I remove all the html from the RB in order to force it to look for the external override?

hope you can help.

Paula

I seem to be getting somewhere with it but its still not right.

Ive set the login.html on the local hotspot to the following:

... $(if chap-id) JavaScript required. Enable JavaScript to continue. $(endif) If you are not redirected in a few seconds, click 'continue' below
\ \ \ Ive also got my rlogin.html set to the following: \ \ \ \ Login body { background-color: #222222; } \ \ I have file.php on my web server running fine with permissions 755 and chown to the web server user as per all other vhosts. md5.js is also there and similarly permissioned. Its all browsable from a normal PC and its also being called when I try to go through the hotspot without logging in. file.php is as follows: <?php $mac=$_POST['mac']; $ip=$_POST['ip']; $username=$_POST['username']; $linklogin=$_POST['link-login']; $linkorig=$_POST['link-orig']; $error=$_POST['error']; $chapid=$_POST['chap-id']; $chapchallenge=$_POST['chap-challenge']; $linkloginonly=$_POST['link-login-only']; $linkorigesc=$_POST['link-orig-esc']; $macesc=$_POST['mac-esc']; ?> mikrotik hotspot > login body {color: #ff7373; font-size: 10px; font-family: verdana;}

textarea,input,select {
background-color: #FDFB00;
border: 1px solid #BBBBBB;
padding: 2px;
margin: 1px;
font-size: 14px;
color: #808080;
}

a, a:link, a:visited, a:active { color: #AAAAAA; text-decoration: none; font-size: 10px; }
a:hover { border-bottom: 1px dotted #c1c1c1; color: #AAAAAA; }
img {border: none;}
td { font-size: 14px; color: #7A7A7A; }

Please log on to use the mikrotik hotspot service

Free trial available, <a style=“color: #FF8080"href=”<?php echo $linkloginonly; ?>?dst=<?php echo $linkorigesc; ?>&username=T-<?php echo $macesc; ?>">click here.


login
password


<?php echo $error; ?>

\ \ I put in my details for a user I have set up on the hotspot user manager but it then seems to go nowhere.

Looking through file.php on the server it seems to call for function doLogin() when post is happening but from there I cant really work out whats happening and its definitely not going any further.

Im hoping somebody can help?

Have you added the domain/IP to the walled garden in the hotspot? That needs to be setup as well for the redirect to work.

Hi Feklar,

Yea I had to work through that earlier but I got there with the walled garden.

Ive actually managed to work this out. My problem was essentially that I had rlogin,html sitting in the same directory as login.html and it was superseding and redirecting (as its supposed to do). That was skewing my results as I tested because rlogin was also pointing to my test server.

Eventually when I tried a new target file I realised that rlogin was keeping things pointed at the original and rlogin was not passing any of the variables up to the server.

So I took it back to basics and got logintest working again. And once Id done that and moved rlogin out of harms way it all clicked into place.

thanks for your suggestion though. :slight_smile:

on to the next challenge. sorting out MAC authentication.

Paula