connect($dbmj_host,$dbmj_user,$dbmj_pw,$dbmj_name); return $db_mj; } ////////////////////////////////////定义门禁数据库 $dbmj_host='localhost'; $dbmj_user='hehe'; $dbmj_pw='hehe'; $dbmj_name='edt'; $dbmj_table_name='MW_EntryList'; //定义进出门ID $enter_door="1"; $out_door="2"; //定义展厅 $zt=""; //////////////////////////////////// include "../tmpl/config.php"; require "../ipad/include/function.php"; require "../ipad/include/db_mysql.php"; define("THIS_FILE_ROOT",dir_cutb(dirname(__FILE__),1)."/ipad"); error_reporting(E_ERROR | E_WARNING | E_PARSE); date_default_timezone_set('Asia/Shanghai'); //-------------------------------register global $magic_quotes_gpc = get_magic_quotes_gpc(); $register_globals = @ini_get('register_globals'); if(!$register_globals || !$magic_quotes_gpc) { @extract(daddslashes($_POST)); @extract(daddslashes($_GET)); } if(!@mysql_connect($dbmj_host,$dbmj_user,$dbmj_pw)) { echo "Can not connect to MJ MySQL server"; exit; } if($_a=="tb"){ header("Content-type: text/html;charset=GB2312"); $db=_mysql_connect_mj(); $q="select * from ".$dbmj_table_name." where status<>'y' order by ReadTime"; $r=$db->query($q); $arr_mj=array(); while($m=$db->fetch_array($r)){ $arr_mj[$m["EPCCode"]][]=$m["DevCode"]; $db->query("update ".$dbmj_table_name." set status='y' where PKID='".$m["PKID"]."'"); } if(count($arr_mj)>0){ $db=_mysql_connect(); $tip=""; // for($i=0;$i0){ $tip.="".$m1["kh"]."-".$m1["color"]."-".get_cate_title_no("color",$m1["color"]); if($arr_mj_door==$enter_door){ $tip.="展示"; $check=get_db_msg("select * from ".$table_pre."kh_tb where "); $db->query("update ".$table_pre."client set available='n' where id='".$m1["id"]."'"); }else{ $tip.="退出"; $db->query("update ".$table_pre."client set available='y' where id='".$m1["id"]."'"); } $tip.="成功!
"; }else{ $tip.="".$arr_mj[$i].",操作失败!
"; } } echo "y|".$tip; }else{ echo "n|"; } exit; } ?> e订通-门禁
e订通-门禁系统
系统等待中......