建了个自动浇水器,有需要的把树苗和花的编号回复过来我给你们加上。
自己建自动浇水器的方法是在管理主页中找主页特效设置,并粘贴代码在||之间加上自己的树苗编号即可,代码是:
<b>批量浇水</b><br>
<textarea style='width:500px;border:1px solid #999;' rows=4 id=treeidlist>184262|252259|4480|4517|9339|10963|11583|11943|12856|14602|19208|19790|21150|22536|22606|23816||26758|27922|28256|28987|
124197|124205|128590||</textarea>
<br><input type=button class=bi style=width:70px; onclick=startwater(); value=批量浇水>
<input type=button class=bi style=width:70px; onclick=clearTimeout(h); value="停 止">
<script language=javascript>
var count=0;
var list;
var h=0;
var k;
function startwater()
{
clearTimeout(h);
list=treeidlist.value.split("|");
k=0;
count=list.length;
water();
}
function water()
{
f1.action="http://tree.ci123.com/tree.php?treeid=".concat(list[list.length-count]);
f1.submit.click();
count-=k;
if(count>0)
{
if(k==0)k=1;
else k=0;
h=setTimeout(water,1000);
}
}
</script>
<form action="" name=f1 method=POST target=tree>
<input type=submit name=submit value="" style=display:none>
</form>