How to determine if a PDO module is installed / disabled?

I am developing a PHP application. I just moved a bunch of files to the production server to find that PDO does not seem to be installed ( Fatal error: Class 'PDO' not found in [file] on line [line]). The prod server uses PHP 5.3.6; according to the documentation I found , "PDO and PDO_SQLITE driver are enabled by default with PHP 5.1.0."

I have very little PHP administration experience. How to find out if this module is installed, but disabled or missing at all? And what do I need to do to run it?

+3
source share
1 answer

Typically, you can just do phpinfo();to find out which modules are installed.

Or from the command line:

php -m

, class_exists('PDO'), , PDO .

+21

All Articles