PHP pg_connect - Mailing list pgsql-general

From Vince
Subject PHP pg_connect
Date
Msg-id 8731effe0707170013w41ac4fe8pd779656aae0069ee@mail.gmail.com
Whole thread Raw
Responses Re: PHP pg_connect
Re: PHP pg_connect
List pgsql-general
When this fails, I get a useful error print:

$dbconn = pg_connect($connection_str);

Ouput:

Warning: pg_connect() [function.pg-connect]: Unable to connect to
PostgreSQL server: FATAL: password authentication failed for user
"postgres1" in ...

How do I capture this error and handle the printing myself?  I want to
be able to know why it failed... ie password in this case.

Thanks,
Vince.

pgsql-general by date:

Previous
From: Richard Huxton
Date:
Subject: Re: Limitations on 7.0.3?
Next
From: "Jason Nerothin"
Date:
Subject: interaction with postgres defined types in custom c functions