PDA

View Full Version : Code Requesting



Xronic
02-27-2015, 09:17 PM
Hello, i would like to know if nay coders know of a script that when you click on a link it goes to the link and opens a new tab. Even if it's in JS.:cool2:

haendler
02-27-2015, 09:29 PM
Hey, how do you exactly mean that?

Do you own a website and want the link to appear in another tab?
Do you want to click on links and they should appear in a new tab?

Xronic
02-27-2015, 09:57 PM
I mean like if you click on a link the tab you clicked on the link in will foawrd to http://link and also open a new tab and go to a link

Angemon
02-27-2015, 11:01 PM
I mean like if you click on a link the tab you clicked on the link in will foawrd to http://link and also open a new tab and go to a link

try this one


<a href="https://a2s.in" target="_blank" onclick="window.open('http://google.com'); window.open('http://skype.com');">Click Me</a>


test it here > Edit fiddle - JSFiddle (http://jsfiddle.net/HGy3f/304/)

if you don't want A2S to be opened in new tab , and you just want the two others to be opened in new tab try this



<a href="https://a2s.in" onclick="window.open('http://google.com'); window.open('http://skype.com');">Click Me</a>

Xronic
02-27-2015, 11:14 PM
thanks alot bro! :D Whoohoo