This forum is no longer active. Please post your questions to our new community site
using pg_connect
|
|
Hi, I am trying to write a simple php program to connect to an existing pg database. PHP Warning: pg_connect(): Unable to connect to PostgreSQL server: could not connect to server: No such file or directory My code is the following: <?php Can someone help me out? Thanks |
|
|
Hi, You should modify the path to the socket using ‘host’ option. The Stack doesn’t use default socket location ( /tmp/.s.PGSQL* ) but <installdir>/postgresql You can try using something similar to this:
I hope it helps |

