Skip site navigation (1) Skip section navigation (2)

Re: [SQL] connecting with password

From: Daniele Orlandi <daniele(at)orlandi(dot)com>
To: PGsql <pgsql-sql(at)postgreSQL(dot)org>
Subject: Re: [SQL] connecting with password
Date: 1998-09-11 02:31:10
Message-ID: 35F88B6E.7F0D9944@orlandi.com (view raw or flat)
Thread:
Lists: pgsql-sql
Eric McKeown wrote:
> 
> Is there any way to set up special password protections for a Postgres
> database, so that I can force someone to present a username and password
> when connecting from a PHP script?  I've combed the docs for something on
> this, and I may just be completely off base on the feasibility.
> 
> Comments appreciated...

I use this to connect with username/password:

$conn=pg_pconnect("host=localhost dbname=db user=me password=foobar");

Not very documented, found with a bit of luck....

Bye!

-- 
 Daniele

-------------------------------------------------------------------------------
"On the Internet, no one knows you're using Windows NT"
(Submitted by Ramiro Estrugo, restrugo(at)fateware(dot)com)
-------------------------------------------------------------------------------
 Se telecom italia aggiungesse uno scatto al giorno ad ogni abbonato, dal
 primo Gennaio avrebbe rubato 803.726.000.000 Lire.
-------------------------------------------------------------------------------
 Daniele Orlandi - Utility Line Italia - http://www.orlandi.com
 Via Mezzera 29/A - 20030 - Seveso (MI) - Italy
-------------------------------------------------------------------------------

In response to

pgsql-sql by date

Next:From: D'Arcy J.M. CainDate: 1998-09-11 03:11:15
Subject: Re: [SQL] connecting with password
Previous:From: Eric McKeownDate: 1998-09-11 02:18:40
Subject: connecting with password

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group