如何添加链接到这些随机图像集。我想分别链接到A B和C,我希望这些颜色相匹配。在我正在处理的页面(我自己的个人艺术网站)中,这些颜色将是图像。随机图像 - 如何添加链接?
http://rollinleonard.com/please-help/
<!DOCTYPE html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Rollin Leonard</title>
</head>
<body>
<SCRIPT LANGUAGE="Javascript">
function banner() { } ; b = new banner() ; n = 0
b[n++]= "<IMG name=randimg SRC='http://rollinleonard.com/please-help/images/green_01.gif' border='0' ALT=''><IMG name=randimg SRC='http://rollinleonard.com/please-help/images/green_02.gif' border='0' ALT=''><IMG name=randimg SRC='http://rollinleonard.com/please-help/images/green_03.gif' border='0' ALT=''>"
b[n++]= "<IMG name=randimg SRC='http://rollinleonard.com/please-help/images/purple_01.gif' border='0' ALT=''><IMG name=randimg SRC='http://rollinleonard.com/please-help/images/purple_02.gif' border='0' ALT=''><IMG name=randimg SRC='http://rollinleonard.com/please-help/images/purple_03.gif' border='0' ALT=''>"
b[n++]= "<IMG name=randimg SRC='http://rollinleonard.com/please-help/images/yellow_01.gif' border='0' ALT=''><IMG name=randimg SRC='http://rollinleonard.com/please-help/images/yellow_02.gif' border='0' ALT=''><IMG name=randimg SRC='http://rollinleonard.com/please-help/images/yellow_03.gif' border='0' ALT=''>"
i=Math.floor(Math.random() * n) ;
document.write(b[i])
</SCRIPT>
</body>
</html>
太棒了!这太酷了。我想我不需要这个应用程序,但我肯定会玩这个。谢谢你的提示。 – Rollin