Computer Hope
Internet & Networking => Web design => Topic started by: ashish1241 on July 25, 2010, 11:43:19 AM
-
How do i get the links to open in new windows>>>>>>
<script language="JavaScript"><!--
//Javascript Created by Computerhope http://www.computerhope.com
//store the quotations in arrays
images = new Array(4);
images[0] = "<a href = 'http://www.yahoo.com'><img src='http://www.uniqueasindia.com/uploads/1/8/2/2/1822982/6553860.jpg?166' alt='Visit Computer Hope'></a>";
images[1] = "<a href = 'http://www.gmail.com'><img src='http://www.uniqueasindia.com/uploads/1/8/2/2/1822982/1396784.jpg?166' alt='Computer History'></a>";
images[2] = "<a href = 'http://www.computerhope.com/index.htm'><img src='http://www.computerhope.com/banners/banner3.gif' alt='Visit Computer Hope'></a>";
images[3] = "<a href = 'http://www.computerhope.com/newslet.htm'><img src='http://www.computerhope.com/banners/banner4.gif' alt='Computer Hope Newsletter'></a>";
index = Math.floor(Math.random() * images.length);
document.write(images[index]);
//done
// --></script><br>
-
Please use the code BBCode tag when posting code in future.
Use the
target="_blank"
attribute on all the <a> tags in the script.
Have you permission to copy that script?