I installed php on a machine that had Apache with php already running. Could it be looking atthe old version of php? Because that version doesn't come with postgre support.
What did:
phpinfo();
say?