I have this JS function who activates when a button is clicked:
function redirect() {
win = window.open(\"$ref\", target=\"_blank\");
win2 = window.open(\"$ref\", target=\"_blank\");
win3 = window.open(\"$ref\", target=\"_self\");
}
First call to window.open opens a new tab in Chrome, second window.open opens a new window and the third window.open successfully "redirects" the original window to $ref.
My question is: why the first and the second window.open open both a tab and a window? Is there any way to open only tabs?
A have solved this problem and create a gist. It open 3 links in tabs.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With