工会web
This commit is contained in:
34
GonghuiWeb/www/adminxx/sip.php
Normal file
34
GonghuiWeb/www/adminxx/sip.php
Normal file
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
//刷新IP地区
|
||||
include_once("../../inc/admin.inc.php");
|
||||
include_once("../../inc/class.php");
|
||||
include_once("../../inc/ips.php");
|
||||
$db=new myConn;
|
||||
$db->links($GG['conn']);
|
||||
if($GG){
|
||||
list($id,$ip)=explode(',',$GG['field']);
|
||||
if($GG[$id]){
|
||||
$ipadd=convertip("../../",$db->getdy($ip,$table,$id."=".$GG[$id]));
|
||||
$db->update($table,"ipadd='".$ipadd."'",$id."=".$GG[$id]);
|
||||
$info="alls=document.getElementById('all').innerHTML;
|
||||
alls=alls-1;
|
||||
if(alls<=0 || !alls) alls='<font color=green>完成</font>';
|
||||
document.getElementById('all').innerHTML=alls;";
|
||||
echo $info;
|
||||
echo "document.write('<font color=#777777> $table $id = ".$GG[$id]." $ip = $ipadd </font>');";
|
||||
//echo "window.scrollTo(0,document.body.scrollHeight);";
|
||||
}else{
|
||||
if(!$GG['all']) $where=" where ipadd=''";//只刷新没有数据的地区
|
||||
echo $Admintop;
|
||||
$rs=$db->query("select ".$GG['field']." from ".$table." $where");
|
||||
$s=$db->rscount($rs);
|
||||
echo "<br>执行总数:<b>".$s."</b> 剩余:<b><span id=all style='color:red;'>".$s."</span></b><br>";
|
||||
for($i=0;$i<$s;$i++){
|
||||
$row=$db->getfetch($rs);
|
||||
echo "<script src='sip.php?conn=".$GG['conn']."&table=".$GG['table']."&field=".$GG['field']."&".$id."=".$row[$id]."'></script><br>";
|
||||
}
|
||||
}
|
||||
}
|
||||
$db->close();
|
||||
unset($GG,$db);
|
||||
?>
|
||||
Reference in New Issue
Block a user