pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
don't show error messages. how?
3+ messages / 3 participants
[nested] [flat]

* don't show error messages. how?
@ 2002-04-19 14:13 Jules Alberts <jules.alberts@arbodienst-limburg.nl>
  2002-04-19 16:39 ` Re: don't show error messages. how? Chadwick Rolfs <cmr@shell.gis.net>
  0 siblings, 1 reply; 3+ messages in thread

From: Jules Alberts @ 2002-04-19 14:13 UTC (permalink / raw)
  To: pgsql-php

hello everybody,

i'm creating a little login screen to connect from PHP to postgresel 
7.2 with adodb. the key part it looks like this:

	include_once('adodb/adodb.inc.php');
	$c=ADONewConnection('postgres7');
	if ($c->PConnect('myserver',$id,$pwd,'mydb')) {
		youreCool();
	} else {
		tryAgain();
	}

this works OK, only when login fails (incorrect user ID, password), i 
just want tryAgain() to run, without any errormessages. that's the 
problem, PConnect() will give an errormessage if it fails, it generates 
html like

	your connection has failed blah blah
	user ID  ___________
	password ___________

how can i suppress the message? with adodb? from within PHP?

TIA for any pointers / help

-- 
Jules Alberts



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: don't show error messages. how?
  2002-04-19 14:13 don't show error messages. how? Jules Alberts <jules.alberts@arbodienst-limburg.nl>
@ 2002-04-19 16:39 ` Chadwick Rolfs <cmr@shell.gis.net>
  0 siblings, 0 replies; 3+ messages in thread

From: Chadwick Rolfs @ 2002-04-19 16:39 UTC (permalink / raw)
  To: Jules Alberts <jules.alberts@arbodienst-limburg.nl>; +Cc: pgsql-php

The @ symbol represses errors... I see someone already suggested that.
You also have the option of capturing this error, for debugging.  Is that
what you want to do?  Yet another option is to turn off errors entirely
externally, then you only have the logs to deal with... a simple tail
command could get you debugging info, if necessary.

hth

On Fri, 19 Apr 2002, Jules Alberts wrote:

> hello everybody,
> 
> i'm creating a little login screen to connect from PHP to postgresel 
> 7.2 with adodb. the key part it looks like this:
> 
> 	include_once('adodb/adodb.inc.php');
> 	$c=ADONewConnection('postgres7');
> 	if ($c->PConnect('myserver',$id,$pwd,'mydb')) {
> 		youreCool();
> 	} else {
> 		tryAgain();
> 	}
> 
> this works OK, only when login fails (incorrect user ID, password), i 
> just want tryAgain() to run, without any errormessages. that's the 
> problem, PConnect() will give an errormessage if it fails, it generates 
> html like
> 
> 	your connection has failed blah blah
> 	user ID  ___________
> 	password ___________
> 
> how can i suppress the message? with adodb? from within PHP?
> 
> TIA for any pointers / help
> 
> -- 
> Jules Alberts
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
> 

Chadwick Rolfs - cmr@gis.net
Cleveland State University - Student
Music Major - The Holden Arboretum Volunteer
Computer Programmer - Student Employee
--*I finally found powdered water;
I just can't figure out what to add to it*--




^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: don't show error messages. how?
@ 2002-04-19 14:23 Timothy_maguire@hartehanks.com
  0 siblings, 0 replies; 3+ messages in thread

From: Timothy_maguire@hartehanks.com @ 2002-04-19 14:23 UTC (permalink / raw)
  To: jules.alberts@arbodienst-limburg.nl; +Cc: pgsql-php; pgsql-php-owner@postgresql.org


Place a '@' before the function.

$c=@ADONewConnection('postgres7');

Tim.

Timothy P. Maguire
Web Developer II
Harte-Hanks
978 436 3325



                                                                                                         
                      "Jules Alberts"                                                                    
                      <jules.alberts@arbodienst-        To:       pgsql-php@postgresql.org               
                      limburg.nl>                       cc:                                              
                      Sent by:                          Subject:  don't show error messages. how?        
                      pgsql-php-owner@postgresql                                                         
                      .org                                                                               
                                                                                                         
                                                                                                         
                      04/19/2002 10:13 AM                                                                
                      Please respond to                                                                  
                      jules.alberts                                                                      
                                                                                                         
                                                                                                         




hello everybody,

i'm creating a little login screen to connect from PHP to postgresel
7.2 with adodb. the key part it looks like this:

 include_once('adodb/adodb.inc.php');
 $c=ADONewConnection('postgres7');
 if ($c->PConnect('myserver',$id,$pwd,'mydb')) {
  youreCool();
 } else {
  tryAgain();
 }

this works OK, only when login fails (incorrect user ID, password), i
just want tryAgain() to run, without any errormessages. that's the
problem, PConnect() will give an errormessage if it fails, it generates
html like

 your connection has failed blah blah
 user ID  ___________
 password ___________

how can i suppress the message? with adodb? from within PHP?

TIA for any pointers / help

--
Jules Alberts

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster







^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2002-04-19 16:39 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2002-04-19 14:13 don't show error messages. how? Jules Alberts <jules.alberts@arbodienst-limburg.nl>
2002-04-19 16:39 ` Chadwick Rolfs <cmr@shell.gis.net>
2002-04-19 14:23 Re: don't show error messages. how? Timothy_maguire@hartehanks.com

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox