Andy Wardley wrote:
Paul Sharpe wrote:

[Fri May 13 10:48:58 2005] [error] access to .../foo.tt2 failed for
127.0.0.1, reason: file error - error: not found

... but that one doesn't.


It looks like you have defined an ERROR handling template (called 'error'?)
which is being invoked to report the error in the foo.tt2 template.  Alas
your error template cannot be found.

Doh! Stupid cut and past button. Fixed. Thanks.

# tail /var/log/apache/error.log

[Fri May 13 14:33:55 2005] [error] access to .../foo.tt2 failed for 127.0.0.1, reason: undef error - Illegal division by zero at .../foo.tt2 line 4.\n

Where's that extra '\n' coming from?

And in passing I noticed

$ cat stupid.tt2
[% 0 / 0 %]

$ tpage stupid.tt2
file error - Illegal division by zero at ./stupid.tt2 line 1.

$ GET http://localhost/stupid/
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<HTML><HEAD>
<TITLE>500 Internal Server Error</TITLE>
...

# tail /var/log/apache/error.log

[Fri May 13 14:38:07 2005] [error] access to .../stupid.tt2 failed for 127.0.0.1, reason:

?

paul

_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to