You are here: Re: [PHP] shell script - disable log output « PHP « IT news, forums, messages
Re: [PHP] shell script - disable log output

Posted by Richard Lynch on 10/01/87 11:10

>> test.php 2> /var/log/test

> I don't really need it to log into a file, but I wanted to prevent it
> from echoing to the screen.

test.php 2> /dev/null

You might even be able to put 2> /dev/null at the end of your #! line...

#!/usr/local/bin/php -q 2> /dev/null

But I dunno if that's gonna work...

> It seems that the extern lib I use should use trigger_error() (or
> user_error()) function instead, which is the traditional way to report
> user-defined errors.

An awful lot of scriptes use die() and error_log() when they should be
using trigger_error()...
http://php.net/trigger_error

die must die. :-)

--
Like Music?
http://l-i-e.com/artists.htm

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация