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

Re: PHP Username & Password Detection From PSQL Database

From: Thom Dyson <TDyson(at)sybex(dot)com>
To: pgsql-php(at)postgresql(dot)org
Subject: Re: PHP Username & Password Detection From PSQL Database
Date: 2004-04-07 14:46:27
Message-ID: OF9541863C.F35C6C86-ON88256E6F.0050BA97-88256E6F.00512806@sybex.com (view raw or flat)
Thread:
Lists: pgsql-php



When the database connection fails, you are still trying to run the
pg_close command.  That can't be good.

> if(!$database)
> {
> echo "Connection Failed<BR>";
> }
>
> else
> {
> <snip do something here>
> }

> pg_close($database);

> ?>

Thom Dyson
Director of Information Services
Sybex, Inc.



pgsql-php-owner(at)postgresql(dot)org wrote on 04/07/2004 07:16:57 AM:

.....

> Though if a different password is used, Access Denied is printed as well
as
> an error,  Warning: Unable to jump to row 0 on PostgreSQL result index 2
in
> /home/webpages/yamkedoo/Tests/brandnew.php on line 16, that I am unable
to
> solve. This applies for all incorrect passwords. Please view my code:


> If anyone can spot any mistakes, i will welcome suggestions ;-)


In response to

pgsql-php by date

Next:From: Andrew McMillanDate: 2004-04-07 19:18:01
Subject: Re: PHP Username & Password Detection From PSQL Database
Previous:From: sundaravelDate: 2004-04-07 14:20:25
Subject: Pie/Bar chart

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