0

Today I have updated my MacBook to OS X 10.12

After the update new configs (httpd.config and php.ini) were added and the old configs was renamed previous. I changed the confignames and everything works finde. Everything? No, postgres was not loaded. I created a phpinfo() test.php to check this. And yes, postgres was not loaded.

A view into the apache error log say:

PHP Fatal error: Call to undefined function pg_connect().

Clay
  • 4,700
  • 3
  • 33
  • 49
Vinay Emmaadii
  • 125
  • 1
  • 11

1 Answers1

0

You have to install it. You can install it as below Ubuntu Terminal sudo apt-get install php5-pgsql

Mac OS Follow this link and let me know https://www.moncefbelyamani.com/how-to-install-postgresql-on-a-mac-with-homebrew-and-lunchy/

After everything is done, You can test by placing this in your index.php file

Patrick R
  • 6,621
  • 1
  • 24
  • 27