NYCPHP Meetup

NYPHP.org

[nycphp-talk] suppress errors in command line script

Marc Antony Vose suzerain at suzerain.com
Fri Nov 19 03:26:34 EST 2004


hi there:

i am trying to use the command line PHP on a server which i didn't 
set up.  it's installed at /usr/bin/php, but whenever invoked, i get 
this:

PHP Warning:  Unknown(): Unable to load dynamic library 
'/usr/lib/php4/pgsql.so' - libpq.so.3: cannot open shared object 
file: No such file or directory in Unknown on line 0


ok...so something wasn't compiled properly...apparently it can't find 
the postgresql library.  i can deal with this later (maybe; i only 
have limited control here).

anyway, this doesn't affect execution of my script, which i have 
tried invoking thusly:

/usr/bin/php -q -d display_startup_errors=0 -d display_errors=0 
/path/to/script.php

it seems like no matter what i do, i can't suppress that PHP Warning 
message, and this is annoying, because the crontab manager is 
emailing me this warning twice every 15 minutes.

anyone know how i can get rid of this temporarily, short of 
installing these Postgresql libraries?

cheers,

-- 
Marc Antony Vose
http://www.suzerain.com/

The cost of liberty is less than the price of repression.
-- W.E.B. Du Bois



More information about the talk mailing list