<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>dengji.html</title>
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="this is my page">
<meta http-equiv="content-type" content="text/html; charset=GBK">
<script type="text/javascript">
var quantity1=0;
var quantity2=0;
var quantity3=0;
var quantity4=0;
function aa(num,a){
for(var i=a*5;i<num;i++) {
var str="img"+(i+1);
var img = document.getElementById(str);
var cc="images/xingyellow2.jpg";
var index=img.src.indexOf(cc);
if(index == -1){
img.src = "images/xingonly.jpg";
}
}
}
function cc(num,a){
if(num<=5) quantity1=num;
if(num>5&&num<=10) quantity2=num-5;
if(num>10&&num<=15) quantity3=num-10;
if(num>15&&num<=20) quantity4=num-15;
for(var i=a*5;i<num;i++) {
var str="img"+(i+1);
var img = document.getElementById(str);
img.src = "images/xingyellow2.jpg";
}
document.getElementById(str).οnmοuseοut=function(){};
for(var j=num;j<(a*5+5);j++) {
var str1="img"+(j+1);
var img1 = document.getElementById(str1);
img1.src = "images/xingonly.jpg";
}
document.getElementById(str).οnmοuseοut=function(){};
}
function qq(num,a){
for(var i=a*5;i<num;i++) {
var str="img"+(i+1);
var img = document.getElementById(str);
var cc="images/xingyellow2.jpg";
var index=img.src.indexOf(cc);
if(index == -1){
img.src = "images/xingyellow1.jpg";
document.getElementById(str).οnmοuseοut=function(){for(var i=a*5;i<num;i++) {
var str="img"+(i+1);
var img = document.getElementById(str);
var cc="images/xingyellow2.jpg";
var index=img.src.indexOf(cc);
if(index == -1){
img.src="images/xingonly.jpg";
}
}};
}
}
}
function testxing(){
alert("服务:"+quantity1);
alert("质量:"+quantity2);
alert("环境:"+quantity3);
alert("价格:"+quantity4);
}
</script>
</head>
<body>
<form action="" name="form1">
<table width="100%" border="0" cellspacing="0" cellpadding="0"
class="bodor">
<tr>
<td width="90" height="24" align="right" class="ditop">
<a name="dianping">添加点评</a>
</td>
<td width="627" align="left" class="ditop">
</td>
</tr>
<tr>
<td align="left" class="tdco1">
<ul>
<li>
服务
</li>
<li>
<img src="images/xingonly.jpg"
οnmοusemοve="qq(1,0)" οnmοuseοut="aa(1,0)" alt="差"
οnmοusedοwn="cc(1,0)" id="img1" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(2,0)" οnmοuseοut="aa(2,0)" alt="一般"
οnmοusedοwn="cc(2,0)" id="img2" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(3,0)" οnmοuseοut="aa(3,0)" alt="好"
οnmοusedοwn="cc(3,0)" id="img3" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(4,0)" οnmοuseοut="aa(4,0)" alt="很好"
οnmοusedοwn="cc(4,0)" id="img4" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(5,0)" οnmοuseοut="aa(5,0)" alt="非常好"
οnmοusedοwn="cc(5,0)" id="img5" />
</li>
<li>
质量
</li>
<li>
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(6,1)" οnmοuseοut="aa(6,1)" alt="差"
οnmοusedοwn="cc(6,1)" id="img6" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(7,1)" οnmοuseοut="aa(7,1)" alt="一般"
οnmοusedοwn="cc(7,1)" id="img7" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(8,1)" οnmοuseοut="aa(8,1)" alt="好"
οnmοusedοwn="cc(8,1)" id="img8" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(9,1)" οnmοuseοut="aa(9,1)" alt="很好"
οnmοusedοwn="cc(9,1)" id="img9" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(10,1)" οnmοuseοut="aa(10,1)" alt="非常好"
οnmοusedοwn="cc(10,1)" id="img10" />
</li>
<li>环境 </li>
<li>
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(11,2)" οnmοuseοut="aa(11,2)" alt="差"
οnmοusedοwn="cc(11,2)" id="img11" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(12,2)" οnmοuseοut="aa(12,2)" alt="一般"
οnmοusedοwn="cc(12,2)" id="img12" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(13,2)" οnmοuseοut="aa(13,2)" alt="好"
οnmοusedοwn="cc(13,2)" id="img13" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(14,2)" οnmοuseοut="aa(14,2)" alt="很好"
οnmοusedοwn="cc(14,2)" id="img14" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(15,2)" οnmοuseοut="aa(15,2)" alt="非常好"
οnmοusedοwn="cc(15,2)" id="img15" />
</li>
<li>
价格
</li>
<li>
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(16,3)" οnmοuseοut="aa(16,3)" alt="差"
οnmοusedοwn="cc(16,3)" id="img16" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(17,3)" οnmοuseοut="aa(17,3)" alt="一般"
οnmοusedοwn="cc(17,3)" id="img17" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(18,3)" οnmοuseοut="aa(18,3)" alt="好"
οnmοusedοwn="cc(18,3)" id="img18" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(19,3)" οnmοuseοut="aa(19,3)" alt="很好"
οnmοusedοwn="cc(19,3)" id="img19" />
<img src=" images/xingonly.jpg"
οnmοusemοve="qq(20,3)" οnmοuseοut="aa(20,3)" alt="非常好"
οnmοusedοwn="cc(20,3)" id="img20" />
</li>
</ul>
</td>
</tr>
</table>
<input type="button" οnclick="testxing();" value="查看星级"/>
</form>
</body>
</html>
===========================================================
改改图片的路径就行了