Is there any easy work around to close the current tab and open a new tab by javascript?
Try below :
window.open('http://www.google.com','_blank');window.setTimeout(function(){this.close();},1000)
you can use location.replace
for same goal:
window.location.replace('https://stackoverflow.com/');
https://developer.mozilla.org/en-US/docs/Web/API/Location/replace
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