[ 本帖最后由 Walter 于 2013-9-28 12:37 编辑 ]\n\n
另外一个方法就是利用半自动机器人,自动运行以下javascript:
<script language="javascript">
<!--
var pxNum=0;
var pxPeople=0;
var id=11049;
var dis=0;
var num=-1;
function ljy_px(num){
var num=parseInt(num);
var px_li=document.getElementById('ljy_pf_3').getElementsByTagName('li');
var px_len=px_li.length;
for(var i=0;i<px_len;i++){
px_li[i].style.background='url([img]http://www.chinacampus.org/templates/default/skins/default/images/px_2.gif[/img])';
if(dis==1){
px_li[i].onmouseout=function(){};
px_li[i].onmousemove=function(){};
px_li[i].onclick=function(){};
px_li[i].style.cursor='default';
}else{
px_li[i].onmouseout=function(){ljy_px_load(pxNum,pxPeople);};
}
}
num= num > 4 ? 4 : num;
for(var s=0;s<=num;s++){
px_li[s].style.background='url([img]http://www.chinacampus.org/templates/default/skins/default/images/px_1.gif[/img])'
}
}
function ljy_px_load(num,people){
var num=parseInt(num);
var people=parseInt(people);
if(num>0 && people>0){
var px_num=Math.round(num/people)-1;
ljy_px(px_num)
}else ljy_px(-1);
}
ljy_px_load(pxNum,pxPeople);
function ljy_px_save(saveNum){
var num=parseInt(saveNum);
ljy_px_save_xmlhttp('http://www.chinacampus.org/include/pingbi_rating.php?num='+saveNum+'&id='+id+"&"+Math.round(Math.random()*10000));
}
function ljy_px_save_xmlhttp(url){
var xmlhttp=null;
if (window.XMLHttpRequest){xmlhttp = new XMLHttpRequest();}
if (!xmlhttp&&window.ActiveXObject){
try{xmlhttp = new ActiveXObject("Msxml2.XMLHTTP.5.0")}
catch(e){try{xmlhttp = new ActiveXObject("Msxml2.XMLHTTP.4.0")}
catch(e){
try{new ActiveXObject("Msxml2.XMLHTTP")}
catch(e){try{new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}}}}}
if(!xmlhttp){alert('您的浏览器不支持该操作!');
}else{
xmlhttp.open("GET",url,true);
xmlhttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded; charset=utf-8");
xmlhttp.send(null);
xmlhttp.onreadystatechange=function(){
if(xmlhttp.readyState==4){
if(xmlhttp.status==200){;
var rs=parseInt(xmlhttp.responseText)-1;
dis=1;
ljy_px(rs);
alert('恭喜,评分成功!谢谢您的参与!');
}else{alert('您的浏览器不支持该操作--!');}
}
}
}
}