<script type="text/javascript"> function mm(){ var ip=new Date().getHours()*300; var vp=ip*3; var line=1000*(3+parseInt(Math.random()*3)); alert("ip="+ip+"|vp="+vp+"|line="+line); window.setTimeout("mm()",1000*60); } window.onload=mm; </script> 不很明白你的意思
function mm(){
var ip=new Date().getHours()*300;
var vp=ip*3;
var line=1000*(3+parseInt(Math.random()*3));
alert("ip="+ip+"|vp="+vp+"|line="+line);
window.setTimeout("mm()",1000*60);
}
window.onload=mm;
</script>
不很明白你的意思
就是html
<a>日IP[现在的小时x300倍] | 今日PV[现在的小时x900倍] | 昨日IP[138885] | 昨日PV[504729] | 当前在线[随机数字,3000或者4000或者5000</a>
<script type="text/javascript">
document.getElementById("todayip").innerHTML = parseInt((new Date().getHours()) * (300 + 100 * Math.random()));
document.getElementById("todaypv").innerHTML = parseInt((new Date().getHours()) * (900 + 100 * Math.random()));
document.getElementById("curonline").innerHTML = parseInt((3000 + 2000 * Math.random()));
</script>
return new Date().getHours()*300;
},function(){
return new Date().getHours()*900;
},function(){
return 昨日IP[138885];
},function(){
return 昨日PV[504729];
},function(){
return (Math.floor(Math.random()*3)+3)*1000;
}];var html=rand[Math.floor(Math.random()*5)]();