这是我在头顶的Javascript。
<script type="text/javascript" charset="utf-8">
var myGallery=new Array();
myGallery[0]="../images/gallery2/2009_09_04-BretErnst_0013.jpg";
</script>
现在我希望能够调用 myGallery[0] 并将其用作 href。
所以我尝试:
<li>
<a href="myGallery[0]" rel="prettyPhoto[gallery1]" title="You can add caption to pictures. You can add caption to pictures. You can add caption to pictures.">
<img src="myGallery[0]" width="60" height="60" alt="Red round shape" />
</a>
</li>
但是变量没有被字符串替换......
帮助?