You are here: Re: PHP equivalent to VB on error resume next « PHP Programming Language « IT news, forums, messages
Re: PHP equivalent to VB on error resume next

Posted by Rik on 07/27/07 09:54

On Fri, 27 Jul 2007 11:42:06 +0200, Buzby <gb@pumpupthe.net> wrote:
> As per the title - is there a VBscript type on error resume next
> function in PHP 4.2xx
>
> Any pointer would be hugely appreciated!

I'm not familiar with VBscript, but you can control error handling quite
good:

http://www.php.net/set_error_handler

Some relevant passage:
"Also note that it is your responsibility to die() if necessary. If the
error-handler function returns, script execution will continue with the
next statement after the one that caused an error. "

Some limitations (pretty obvious offcourse..):
"The following error types cannot be handled with a user defined function:
E_ERROR, E_PARSE, E_CORE_ERROR, E_CORE_WARNING, E_COMPILE_ERROR,
E_COMPILE_WARNING, and most of E_STRICT raised in the file where
set_error_handler() is called."
http://nl2.php.net/manual/en/ref.errorfunc.php#errorfunc.constants

Then again, fatal is fatal, and ignoring errors is not a very good way to
go in most cases. Some extra checks before actions help out a lot.
--
Rik Wasmus

 

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

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