>> <?php header("Location:  http://somewhere.com/error.php?errno=4";); ?>
>
>> This way, users who don't care can still re-direct a browser 
>to a nice 
>> and pretty "sorry, the server is really screwed" HTML page... Or, if 
>> they'd like, they can simply take that error number and create a 
>> error-handler in PHP without us having to bother with the problems 
>> surrounding a bad parser-state...
>
>I don't think this will work. First of all PHP would have to 
>do output buffering as sending an header() after output has 
>been sent wont work.

Simply fixed if you fix output buffering to ON if you are using a custom
re-direct handler for errors.

>Also if I allow users to input PHP code to allow for greater 
>customization of an application then I wouldn't want eval() to 
>redirect you to the page saying the site is down for 
>maintenance when they preview their script. (I'd rather have 
>eval() create a non fatal error so I can give them a more 
>useful error message.)

What are you doing giving users access to eval()??? That's an incredibly
huge security risk allowing an arbitary user to execute code of their
choosing on your server... (I shiver to think if you actually had the
PEAR Inline_C installed....).. Besides, as with all of the directives in
this nature, a function or two could be created to get/set this
directive as necessary from PHP code.

>If people are updating a site with code they haven't tested 
>then you probably are not running a major site, or shouldn't 
>be. If you expect things to break while doing an upgrade it is 
>easy enough to force the web server to serve an "Upgrade in 
>progress page."

Valid, but I'd be careful being too judgemental... I've seen some pretty
big web sites doing some pretty stupid things ... Putting untested code
on them is sometimes the least of it.

John


>-- 
>Kjartan <[EMAIL PROTECTED]> (http://natrak.net/)
>:: "Choose your friends by their character and your socks by
>    their color. Choosing your socks by their character makes
>    no sense, and choosing your friends by their color is
>    unthinkable."
>
>


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to