【www.gdgbn.com--mysql教程】
$conn=mysql_connect("localhost","root","2328725");
mysql_select_db("novel");
mysql_query("set names "utf8"");
if($provincecode!=""&&$provincecode!=650000&&$provincecode!=710000&&$provincecode!=810000&&$provincecode!=820000&&$provincecode!=110000&&$provincecode!=120000&&$provincecode!=310000&&$provincecode!=500000){
$sql="select * from city where provincecode=$provincecode";
$result=mysql_query($sql);
echo ";
echo "\n";
while($row=mysql_fetch_row($result)){
echo "\n";
}
echo "\n";
}
if($citycode!=""){
$sql="select * from area where citycode=$citycode";
$result=mysql_query($sql);
echo ";
echo "\n";
while($row=mysql_fetch_row($result)){
echo "\n";
}
echo "\n";
}
?>