open link in new tab javascript
snippet in javascript

open link in new tab javascript

user3591

window.open('https://www.codexworld.com', '_blank');

javascript open link in new tab

user7266

function NewTab() { 
            window.open( 
              "https://www.yourURL.com", "_blank");
}

javascript open url

user3481

window.location.href = "http://example.com/";

javacript open url in new tab

user6842

window.open(url,'_blank');
window.open(url);

javasript onclick open page in new tab

user863


window.open("https://www.w3schools.com");