Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 2E22F2E027D for ; Mon, 10 Mar 2008 15:44:29 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 80565-04 for ; Mon, 10 Mar 2008 15:44:16 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from mail04.svc.cra.dublin.eircom.net (mail04.svc.cra.dublin.eircom.net [159.134.118.20]) by postgresql.org (Postfix) with SMTP id 7FFEB2E031D for ; Mon, 10 Mar 2008 15:44:19 -0300 (ADT) Received: (qmail 87371 messnum 3252837 invoked from network[86.42.26.2/86-42-26-2.b-ras1.mvw.galway.eircom.net]); 10 Mar 2008 18:44:17 -0000 Received: from 86-42-26-2.b-ras1.mvw.galway.eircom.net (HELO ?127.0.0.1?) (86.42.26.2) by mail04.svc.cra.dublin.eircom.net (qp 87371) with SMTP; 10 Mar 2008 18:44:17 -0000 Message-ID: <47D58181.2080205@iol.ie> Date: Mon, 10 Mar 2008 18:44:17 +0000 From: Raymond O'Donnell Reply-To: rod@iol.ie User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: John Cartwright CC: pgsql-php@postgresql.org Subject: Re: pg_connect fails, pgsql works References: <47D571EF.8020408@noaa.gov> In-Reply-To: <47D571EF.8020408@noaa.gov> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Antivirus: avast! (VPS 080309-0, 09/03/2008), Outbound message X-Antivirus-Status: Clean X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/6 X-Sequence-Number: 3831 On 10/03/2008 17:37, John Cartwright wrote: > $con = pg_connect("host='postgres1.ngdc.noaa.gov' port=5432 > sslmode='allow' user='test' password='mypassword' dbname='test'") I don't think you need to quote the host, uid, etc - try it without the single quotes, e.g. "host=postgres1.ngdc.noaa.gov port=5432 sslmode=allow user=test [....]" HTH, Ray. --------------------------------------------------------------- Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland rod@iol.ie ---------------------------------------------------------------