PHP PDO extension not available on command line

I switched from WAMP to EasyPHP, and now there are problems using PDO. PDO works great when viewing a site in a browser, but it doesn’t work in cmd or when running a test file through Netbeans. I get:

"PDOException: Could not find driver"

In phpinfo()for the Setup command I have

cscript /nologo configure.js " --enable-snapshot-build" " --disable-isapi" " --enable-debug-pack" " --disable-isapi" " --without-mssql" " --without-pdo-mssql" " --without-pi3web" " --with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk, shared" " --with-oci8=D:\php-sdk\oracle\instantclient10\sdk, shared" " --with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk, shared" " --enable-object-out-dir=../obj/" " --enable-com-dotnet" " --with-mcrypt=static" " --disable-static-analyze"

As php.iniI have already uncommented these lines:

extension=php_pdo_mysql.dll

extension=php_mysql.dll

Any ideas on how I can make this work?

+5
source share
3 answers

php -c --php-ini, php.ini . php.ini . php php -c/path/to/php.ini, script .

+5

- Linux Windows 2 php.ini. CLI ( ) APACHE , easyphp.

, , Linux EasyPHP, , , ?

+2

. , PHP .ini CLI. php-cli.ini php, .

0
source

All Articles