Home  >  Article  >  Backend Development  >  虚拟主机里为什么php连不了access解决方案

虚拟主机里为什么php连不了access解决方案

WBOY
WBOYOriginal
2016-06-13 13:46:03919browse

虚拟主机里为什么php连不了access

  include('adodb5/adodb.inc.php');

  $db =& ADONewConnection('access');
  $dsn = "Driver={Microsoft Access Driver (*.mdb)};Dbq=".realpath("aa/bb.mdb").";Uid=;Pwd=;";
  $db->Connect($dsn);
   
  $rs = $db->Execute('select * from question');

  print "

";<br>     print_r($rs->GetRows());<br>     print "
";

?>

在本地没问题,遗传到空间上,就报500,服务器内部错误。。不解。。。空间支持access的啊

------解决方案--------------------
$db ->debug = true;
------解决方案--------------------
开启error_reporting(E_ALL)试试,看看有没错误....
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn