Community discussions

MikroTik App
 
andrescamino
Member Candidate
Member Candidate
Topic Author
Posts: 198
Joined: Wed Aug 19, 2009 7:07 pm
Location: Guayaquil-Ecuador

New Tab after login

Tue Aug 25, 2009 6:41 pm

Hi,

I was wondering if I can create some kind of link to open a new tab in the browser or new page because once the user logs in at the hotspot I can´t see what is the time that is left, or how can the user logout.
I know that I can put in the web browser http://hotspot-ip/logout but that would be a problem because the user doesn´t really know this, it would be easier if I can leave the page that gives the remaining time and the logout option, and automatically open a new tab where the user can actually actually surf online.

I know a little bit of HTML, and I changed the appearence of the login and logout front-end, but I can´t figure out int he POST section (to login) how to create a new tab from there...something like target="_new" to send the user to another tab once he logs in.

Thanks for your help
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: New Tab after login

Tue Aug 25, 2009 6:53 pm

That would be equivalent to a pop up, and blocked by most browsers (or add-ons).

Felix
 
andrescamino
Member Candidate
Member Candidate
Topic Author
Posts: 198
Joined: Wed Aug 19, 2009 7:07 pm
Location: Guayaquil-Ecuador

Re: New Tab after login

Tue Aug 25, 2009 7:15 pm

Hi Felix,

I have a question, I changed a little bit the script after the person logs in and created a link to another tab in google...my question is...once a do it...it actually accepts it but it goes automatically...i want to mantain the login page where appears the session time, and how much time is left, and not appear in google automatically
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: New Tab after login

Tue Aug 25, 2009 7:32 pm

Automatically popping up a window or new tab after login will be blocked by most modern browsers out of the box.

I'd think the cleanest solution is to have your status page contain a link that pops to new window or tab with big bright letters announcing to "Click here to go to your original destination", and have that link to the customer's originally requested URL. With a bit of luck most people won't close the status tab that will still be open.

But again: you cannot reasonably automate that action. From a technical point of view, what you want to do is 100% equivalent to an automated pop-up showing advertising. People hate automated pop-ups showing advertising, and accordingly browsers have gotten rather good at blocking them.

Felix
 
andrescamino
Member Candidate
Member Candidate
Topic Author
Posts: 198
Joined: Wed Aug 19, 2009 7:07 pm
Location: Guayaquil-Ecuador

Re: New Tab after login

Tue Aug 25, 2009 7:43 pm

Hi Felix,

Ok you explained really clear.

Now I´ll change my question. How do I make a link at the user´s end to open the status? because the user won´t have the knowledge to go to http://hotspot-ip/status or can I put as a principal page in the users end the status page after they login to the hotspot?...i guess i can put some instructions in the status so they don`t close and actually put a link to open a new window or tab
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: New Tab after login

Tue Aug 25, 2009 7:47 pm

Exactly. Redirect users to the status page after login, and modify the status page to explain that the users should keep this page open, and to use other windows/tabs to browse the net.

Felix
 
andrescamino
Member Candidate
Member Candidate
Topic Author
Posts: 198
Joined: Wed Aug 19, 2009 7:07 pm
Location: Guayaquil-Ecuador

Re: New Tab after login

Tue Aug 25, 2009 7:52 pm

okay felix, thanks

how do i redirect the users to the status page?
where should I change the code, in login or alogin or redirect file?

Thanks for your help
 
andrescamino
Member Candidate
Member Candidate
Topic Author
Posts: 198
Joined: Wed Aug 19, 2009 7:07 pm
Location: Guayaquil-Ecuador

Re: New Tab after login

Tue Aug 25, 2009 8:12 pm

Hey felix,

Thanks for your advice, I did it, I had to change the html file of "alogin", just after the endif

there is a url called link-redirect....and it has to be changed to link-status and it works great just as you said.

Thanks a lot

Who is online

Users browsing this forum: No registered users and 20 guests