ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> php-general
php-general
Re: [PHP] Error Display
by Jochem Maas other posts by this author
Dec 13 2006 12:04PM messages near this date
[PHP] [so O T that it hurts :-)] Re: [PHP] file uploads Q? | [PHP] Re: utf8 encoding £ to £ problem
Craige Leeder wrote:
>  I have been working with PHP5 since it's release, and until a few
>  months ago, have never experienced the problem I am about to describe
>  to you. I am not sure weather it has been discovered previously or
>  not, nor do I know exactly how to replicate it, but I would like to
>  know if you have encountered the problem as well. The problem is this:
>  
>  I have noticed that there appears to be (fatal) errors that do not
>  show when they occur in an included file. The script simply halts
>  execution, and returns headers to the browser. I do not have a list of
>  the errors that do not display, but I do not believe it applies to all
>  fatal errors.
>  
>  The errors show perfectly fine when the file is called directly from
>  the php parser (/through the browser), just not when included. This is
>  an extreme annoyance, and would like to know if it has been
>  discovered. As far as I can tell, the errors seem to apply mostly to
>  Objects and classes, but I cannot be certain. I have not run too many
>  tests on the problem.

I have run into this issue since almost the beginning of php5 - never
really have got a handle on it.

what I do know is that it's, in my case, always/only occurs in cases
where syntax error causes an included file to fail to parse. I also
know that it's only occurs when the complexity of an application
rises above a certain level - I've never been able to reproduce

using a debugger to step through code that is giving the blank page
always makes the fatal error 'appear' (i.e. the debugger returns
the error) - at least that is what I found when I last test ZDE.

whenever I get the blank screen of death (PBSOD?) I run the following
cmdline in the root directory of the project in question (you
may need to change it a bit to suit your needs), it quickly tells you
what is not parsing (it assumes your code is running on a real OS ;-):

	find . -name \*.php \! -exec php -l {} \;

>  
>  Although it should not need to be stated, I do have error reporting
>  set to E_ALL.

are you sure there is nothing changing the error_reporting or display_errors
somewhere in the code (maybe some third party code) - I vaguely remember being
caught out by Smarty's error handling code with respect to this problem.

anyway no real answers from me, but at least you know your not alone ;-)

>  
>  - Craige
>  

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved