0

When I want to see my php version, use the command php -v, there show some warnings. How to solve it?

enter image description here

PHP Warning: PHP Startup: Unable to load dynamic library '/Applications/Server.app/Contents/ServerRoot/usr/lib/php/extensions/no-debug-non-zts-20121212/pdo_pgsql.so' - dlopen(/Applications/Server.app/Contents/ServerRoot/usr/lib/php/extensions/no-debug-non-zts-20121212/pdo_pgsql.so, 9): image not found in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library '/Applications/Server.app/Contents/ServerRoot/usr/lib/php/extensions/no-debug-non-zts-20121212/pdo_pgsql.so' - dlopen(/Applications/Server.app/Contents/ServerRoot/usr/lib/php/extensions/no-debug-non-zts-20121212/pdo_pgsql.so, 9): image not found in Unknown on line 0

marian0
  • 3,336
  • 3
  • 27
  • 37
lidechao
  • 3
  • 4
  • 3
    Possible duplicate of [Enabling PostgreSQL support in PHP on Mac OS X](http://stackoverflow.com/questions/6588174/enabling-postgresql-support-in-php-on-mac-os-x) – marian0 Oct 14 '15 at 07:12

1 Answers1

0

You have a php configuration file that try to loads the pdo_pgsql.so library, but the library isn't installed correctly.

You can either disable the library loading by removing the configuration directive loading it (you should have something like this:extension=pdo_pgsql.so) or install the pdo for php correctly.

kitensei
  • 2,510
  • 2
  • 42
  • 68