脚本代码(For Alixixi.com)如下:
无标题文档#div0{
width:700px;
height:500px;}
#div1{
width:300px;
height:200px;
float:left;
background-color:#CCCCCC;}
#div2{
width:300px;
height:200px;
float:right;
background-color:#F00;}
window.οnlοad=function(){
var oto1=document.getElementById('div1');
var oto2=oto1.getElementsByTagName('li');
var oto3=document.getElementById('div2');
for(var i=0;i
oto2[i].index=i;
oto2[i].οnclick=function(){
oto3.innerHTML=oto2[this.index].innerHTML;
}
}
}