Your PHP installation does not support PostgreSQL. You need to recompile PHP using the --with-pgsql configure option.