How Can I Open Two Urls In Two Tabs In A Single Click?
I have 2 urls http://www.example.com and http://www.nana.com If I click the below link the above 2 urls should open in two tabs.. a href='#'>Click /a May anyone help me to
Solution 1:
Try something like this :
<aid="test"href="#"> CLick </a><scripttype="text/javascript">document.getElementById("test").onclick = function(){
window.open("http://www.google.com",'_blank');
window.open("http://www.p3php.in",'_blank');
}
</script>
Solution 2:
This should work:
<ahref="http://www.example.com"onclick="window.open('http://www.nana.com')">Click</a>
Solution 3:
Try something like this :
<ahref="#"onclick="window.open('http://google.com');
window.open('http://yahoo.com');" >Click</a>
Solution 4:
Better way to do it
HTML:
<a id="link">Click me!!</a>
JS:
var link = document.getElementById("link");
link.onclick = function() {
window.open("http://yahoo.com");
window.open("http://google.com");
};
Cheers!!
Solution 5:
hope this works
<html><script>functionpageloader()
{
window.open("http://www.example.com", '_blank');
window.open("http://www.google.com", '_blank');
}
</script><body><ahref="#"onclick="pageloader();">Click here </a></body></html>
goodluck!
Post a Comment for "How Can I Open Two Urls In Two Tabs In A Single Click?"