Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

javascript

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have inserted a javascript to start a game. This is the script:

<!--
if (navigator.appName === &quot;Netscape&quot;)
{
document.write (&quot;<a href=tetrisNN2.html><b>Geavanceerde Tetris</b></a>&quot;)
document.write (&quot;&amp;nbsp &amp;nbsp(U gebruikt Netscape Navigator)&quot;)
}
else
if (navigator.appName === &quot;Microsoft Internet Explorer&quot;)
{
document.write (&quot;<a href=tetrisIE2.html><b>Geavanceerde Tetris</b></a>&quot;)
document.write (&quot;&amp;nbsp &amp;nbsp(U gebruikt Internet Explorer)&quot;)
}
else
document.write (&quot;<br />U moet Netscape of IE als browser hebben om Geavanceerde Tetris te kunnen spelen<&quot;)
//-->

Now what I want to do is the following: I want to open a new window when the person clicks on the link to the game. I've already tried to insert 'target=&quot;_blank&quot;' into the a href tag but that doesn't work. How do I do this :)
 
Have you tried it with the quotes around the href? So it reads

document.write (&quot;<a href='tetrisNN2.html' target='_blank'><b>Geavanceerde Tetris</b></a>&quot;)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top