This is the code:
function openUrl(url) {
var newTab = window.open(url, '_blank');
if (!newTab || newTab.closed) {
}
}
}
if there is popup blocker the tab isnt opening so i need to do something that it will be open with popup blocker on. If you have any solution that doesnt involve new button I will be happy to hear! If there is no solution so maybe add confirm and work with that. I tried to add confirm in the if and open new tab with the click trigger but nothing.
I tried to put this in the if:
var a = document.createElement('a');
a.target="_blank";
a.href=url;
a.click();
but nothing Please help Thank you!