Redirecting to URL after Hotspot login...

Hi All,

Does anyone how to set config, so that once user logs in using Hotspot, he is automatically redirected to our web page and not original page requested? I have tried editing the login.html page changing the orig link to desired web page, but that hasnt helped.

Any suggestion is highly welcomed.

Thanks
Medube

Try using webserver on some of your pc’s (example 192.168.1.100),
then in MT dst-nat use this:

add src-address=192.168.1.0/24 action=nat to-dst-address=192.168.1.100
to-dst-port=80

All users will be redirected to your page.

Cheers…

Hi Djape,

Thanks for the info, but I dont think you understood the question well. Now under hotspot when user obtains an IP, he/she opens up IE and requests for example http://www.google.com, he/she is automatically redirected to the hotspot login page. Once he/she puts in user name and pass and logs in, he is automatically sent to http://www.google.com. Now what I want is no matter what is requested, lets say http://www.google.com again, user will automatically be redirected to our webpage as first page after login.

I hope this paints a better picture.

Medube

OH, well, sorry :frowning: to much beer I guess :smiley:

Hm? I must check with my partner, I am sure that he made this to work.

Be back with some useful info…

Cheers…

Thanks for the help so far djape. I hope to be hearing from you very soon :sunglasses:

medube

http://www.mikrotik.com/docs/ros/2.8/ip/hotspot

To choose different page shown after login, in login.html change:

to this line:

(you should correct the link to point to your server)

I have tried editing the login.html page changing the orig link to desired web page, but that hasnt helped.

Did you read that part of my first message?

medube

No, but yes, it’s the same problem I have run into. Try it with non-encrypted password set. I believe the hashing thingy overwrites it with the old. I’ve raised it with Mikrotik ages ago but haven’t received a reply.

We will change the documentation.
Current method when you change the login.html will work only in case of PAP authentication.

You should modify the alogin.html file and replace this line:

location.href = '%link-redirect%';

with this line:

location.href = 'http://your.web.server';

And also this line:

<td align="center" valign="bottom" height="50px">If still nothing happens, press <a href="%link-redirect%">here</a></td>

with this line:

<td align="center" valign="bottom" height="50px">If still nothing happens, press <a href="http://your.web.server">here</a></td>

Thanx a lot Uldis, that really solved the whole problem.

Medube

Following on from this thread - is it possible to do an HTTP post of username/password from a different server direct to the hotspot’s alogin.html page?

So when a customer payment has been authorised on our payment server it could populate a form on that server with username and password that posted to the hotspot’s authorisation page.

What elements would be needed on the form?

Trisc