2016-12-29 291 views
0

我正在使用odbc和XAMPP。我收到的致命错误,找不到驱动程序PDO:Uncaught PDOException:找不到驱动程序

Fatal error: Uncaught PDOException: could not find driver in C:\xampp\htdocs\index.php:5 Stack trace: #0 C:\xampp\htdocs\index.php(5): PDO->__construct('odbc:BEGIN') #1 {main} thrown in C:\xampp\htdocs\index.php on line 5

这是指的错误代码:

$conn = new PDO ("odbc:BEGIN"); 

有,我应该增加这样的php.ini中的任何模块answer还是有其他解决方案?

回答

1

您需要启用以这些扩展有ODBC驱动程序PDO工作

php_pdo.dll 
php_odbc.dll 
php_pdo_odbc.dll 
+0

谢谢@Sarhan –

0

使这些扩展作为@Sarhan后说,我们需要重启阿帕奇以便为它工作。

+0

我明白了:)。它现在工作。谢谢@法尔 –

+0

非常欢迎;)@Mint – Far

+0

谢谢澄清@远,我应该提到 – Sarhan

相关问题