最基本的连接,输出

 

$conn = mysql_connect('localhost', 'root', '');
//mysql_query("SET NAMES 'gbk'", $conn);
mysql_select_db('sim', $conn);
$strSQL = "select * from sim_stui_nfo";
$rs=mysql_query($strSQL);

if (($num=mysql_num_rows($rs))>0){
    $row=mysql_fetch_array($rs);

    echo $row["name"];
}

 

 

 

 

 

相关文章:

  • 2021-12-18
  • 2021-11-06
  • 2022-12-23
  • 2022-02-07
猜你喜欢
  • 2022-12-23
  • 2021-11-17
  • 2021-12-26
  • 2021-10-22
  • 2021-07-15
相关资源
相似解决方案