include("config.php");header("Content-Type:text/html;charset=gbk_2312");$conn=mysql_connect($config_ip,$config_name,$config_pass)ordie("链接错误");mysql_select_db($config...
include("config.php");
header("Content-Type: text/html;charset=gbk_2312");
$conn = mysql_connect($config_ip,$config_name,$config_pass) or die ("链接错误");
mysql_select_db($config_dbname,$conn);
mysql_query("set names 'GB2312'");
$conn1 = @mysql_connect($config_ip1,$config_name1,$config_pass1,true) or die ("链接错误");
mysql_select_db($config_dbname1,$conn1);
mysql_query("set names 'GB2312'");
function row1(){
$sql="select * from $config_dbname.systemparameters ";
$query=mysql_query($sql);
if($q=mysql_fetch_array($query)){
return $q[0];
}else{
return $query;
}
}
function row2(){
$sql1="select * from $config_dbname1.dg_area ";
$query1=mysql_query($sql1);
if($q1=mysql_fetch_array($query1)){
return $q1[3];
}else{
return $false;
}
}
结果
NULL 110100
展开