<html><head>
<script language="Javascript">
<!--
var text="白日依山尽!";
var textshow="";
var textsize=40;
var location=150;
var space=0.7;
var textlength=text.length;
y=-1000;
for(x=0;x<textlength;x++){
textshow=textshow+'<div id=L'+x+' style="width:3;font-family:隶书;font-
weight:bold;position:absolute;top:90;left:250;z-index:0">'+text.charAt(x)
+'</div>'
}
document.write(textshow);
Time=window.setInterval("effect()",10);
angle=5;
angle1=0.05;
function effect(){
angle=angle+angle1;
for(x=0;x<textlength;x++){
angle2=angle+space*x;
num1=Math.cos(angle2);
thistext=document.all("L"+x);
thistext.style.posLeft=location+100*Matn.sin(angle2)+50;
thistext.style.zIndex=60*num1;
thistext.style.fontSize=textsize+30*num1;
thistext.style.color="rgb("+(227+num1*10)+","+(50+num1*190)+","+
(30+num1*220)+")";
}
}
//-->
</script></head>
<body></body></html>
从书上抄的,大家帮忙看一下.谢谢.
[此贴子已经被作者于2007-4-26 20:15:32编辑过]