Monday 15 April 2013

javascript - Open a URL in a new Tab -



javascript - Open a URL in a new Tab -

this question has reply here:

focus tab or window 10 answers

i want open url in new browser tab javascript or jquery. , if it's been opened, tab selected.

i utilize function open.

function openinnewtab(url) { var win = window.open(url, '_blank'); win.focus(); }

what should if tab open?

see here:

how alter browser focus 1 tab another

and here:

detect if browser tab has focus

both of previous stack overflow posts.

it's possible know when on tab, , when user moves away (using new page visibility api)

but it's not possible switch tab using javascript.

you (which much uncertainty applies in case) write external programme operating scheme communicate browser application , switch way, straight web page, it's non starter , huge security risk.

javascript jquery

No comments:

Post a Comment