原生php mysql链接

1.原生连接代码

   $test = "select count(*) count from dede_userphone where phone=".$mobile;
    $coon = @mysql_connect('$host','$user','$password');
    @mysql_query("SET NAMES UTF8");
    @mysql_select_db('dede_qizheng',$coon);
    $res = @mysql_query($test,$coon);
   while($re = mysql_fetch_array($res))
    {
        array_push($arr,$re);
    }
    echo '<pre>';
    var_dump($arr);
    exit;
    原文作者:mmy123456
    原文地址: https://segmentfault.com/a/1190000007310114
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞