PHP uses PDO to connect to the ACCESS database
1, refer to W3CSHOOL
http://www.w3cschool.cc/php/php-pdo.html
2, connect access
The code is as follows:
$db = new PDO("odbc:driver={microsoft access driver (*.mdb)};
dbq=".realpath("data.mdb"))
or die("Connect Error");
$rs = $db->query('select * from user');
print "
";<br>
print_r($rs->fetchAll());<br>
print "
";
The above is a simple and practical method to connect to the ACCESS database using PDO pdo method. I hope you will like it.
http://www.bkjia.com/PHPjc/963986.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/963986.htmlTechArticlePHP uses PDO to connect to ACCESS database 1, refer to W3CSHOOL http://www.w3cschool.cc/php/php- pdo.html 2. The connection access code is as follows: ?php $db = new PDO(odbc:driver={microsoft access driver...