<script language="javascript" type="text/javascript">
function changeit(img)
{
if ( img == 'sohu')
{
var si = document.getElementById('sina');
var so = document.getElementById('sohu')
si.style.zIndex = 3;
so.style.zIndex = 4;
}
else if ( img == 'sina')
{
var si = document.getElementById('sina');
var so = document.getElementById('sohu')
si.style.zIndex = 4;
so.style.zIndex = 3;
}
}
</script>
</HEAD><BODY>
<div id="con" style="position:absolute;z-index:2;">
<br/><br/>
<img id="sina" src="http://www.sina.com/images/NA01.gif" style="position:absolute;z-index:3">
<img id="sohu" src="http://images.sohu.com/uiue/sohu_logo/2005/index_logo.gif" style="position:absolute;z-index:4">
</div>
<select onchange="changeit(this.value);">
<option value='sohu'>SOHU is over</option>
<option value='sina'>SINA is over</option>
</select>
</BODY>
</HTML>
function changeit(img)
{
if ( img == 'sohu')
{
var si = document.getElementById('sina');
var so = document.getElementById('sohu')
si.style.zIndex = 3;
so.style.zIndex = 4;
}
else if ( img == 'sina')
{
var si = document.getElementById('sina');
var so = document.getElementById('sohu')
si.style.zIndex = 4;
so.style.zIndex = 3;
}
}
</script>
</HEAD><BODY>
<div id="con" style="position:absolute;z-index:2;">
<br/><br/>
<img id="sina" src="http://www.sina.com/images/NA01.gif" style="position:absolute;z-index:3">
<img id="sohu" src="http://images.sohu.com/uiue/sohu_logo/2005/index_logo.gif" style="position:absolute;z-index:4">
</div>
<select onchange="changeit(this.value);">
<option value='sohu'>SOHU is over</option>
<option value='sina'>SINA is over</option>
</select>
</BODY>
</HTML>
比如z-index:zIndex
background-color:backgroundColor
<HTML><HEAD>
<TITLE>fantiny</TITLE>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<META NAME="Generator" CONTENT="PhotoImpact">
<META NAME="Keyword" CONTENT="fantiny,game.">
<META NAME="Author" CONTENT="fantiny"><style type="text/css">
<!--
body{font-size:13px; /*tppabs="pkq_2.bmp"*/
COLOR: #ff9650
}p{ font-size:13px;
COLOR: #ff9650
}
td { font-size: 13px
COLOR: #ff9650;
}
a{ COLOR: #ff9650;
TEXT-DECORATION:none;
font-size:16px}
}
-->
</style><SCRIPT language=javascript>Phrase="1234567890ABC";
Balises=""
Taille=20;
Midx=100;
Decal=0.5;
Nb=Phrase.length;
y=-10000;
for (x=0;x<Nb;x++){
Balises=Balises + '<DIV Id=L' + x + ' STYLE="width:3;font-family: Courier New;font-weight:bold;position:absolute;top:40;left:50;z-index:0">' + Phrase.charAt(x) + '</DIV>'
}
document.write (Balises);
Time=window.setInterval("Alors()",10);
Alpha=5;
I_Alpha=0.05;function Alors(){
Alpha=Alpha-I_Alpha;
for (x=0;x<Nb;x++){
Alpha1=Alpha+Decal*x;
Cosine=Math.cos(Alpha1);
Ob=document.all("L"+x);
Ob.style.posLeft=Midx+100*Math.sin(Alpha1)+50;
Ob.style.zIndex=20*Cosine;
Ob.style.fontSize=Taille+15*Cosine;
Ob.style.color="rgb("+ (27+Cosine*80+50) + ","+ (127+Cosine*80+50) + ",0)";
}
}</SCRIPT></HEAD><BODY LEFTMARGIN="0" MARGINWIDTH="0" TOPMARGIN="0" MARGINHEIGHT="0" bgcolor="#ffffcc" OnLoad="getwindowsize()" OnResize="getwindowsize()">
</BODY></HTML>