Re: [SMARTY] Re: Debugging custom template resource

Marcus Bointon <[email protected]>
Newsgroups gmane.comp.php.smarty.general
Message-ID <[email protected]>
On 24 Oct 2005, at 11:49, Pedro wrote:

> try switching error_reporting(E_ALL)
> Switch off buffering and caching in the testing.production stage

Already doing those. I can't cache anyway because I know that every  
request will generate unique output.

> use {debug} tags withing a template

Nice idea, but that comes too late in the sequence of things. I've  
managed to ascertain that the no results problem IS down to bad  
templates, but it still doesn't explain why I'm not seeing any  
errors, even in my logs. If I use a simple template like 'hello', it  
works, but if I have a larger template that has some unknown  
corruption, I get no errors, it just never returns from the function.  
I've tried out different forms of corruption: {$blah} where $blah is  
undefined doesn't give any errors, but does still work. {blah} where  
blah is an unknown tag causes an immediate exit of the whole script,  
but still no error messages. Because of the context I guess it's hard  
for an error message to 'escape', but a fatal error is not a friendly  
way to handle it - is there an exception throwing patch for Smarty?  
Or is that due in 3.0? Now that php_check_syntax is now obsolete, is  
there any way to deal with bad templates elegantly?

Marcus
-- 
Marcus Bointon
Synchromedia Limited: Putting you in the picture
[email protected] | http://www.synchromedia.co.uk

-- 
Smarty General Mailing List (http://smarty.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.