If you make PHP a module this will work just fine.  As a CGI I'd have to
have a look at the code.  There may or may not be a way to solve this, but
it would require code changes.

-Rasmus

On Wed, 4 Jul 2001, Laurent INFOS wrote:

> Hello,
>
> I have :
>  - Apache 1.3.x
>  - PHP 4.0.5 (not a module, but a separate script)
>  - the directive ErrorDocument is configurated :
>     ErrorDocument 404 /404.html
>
> My problem :
>  - http://server/filenotpresent
>     gives a 404 error, and open 404.html. It's OK.
>  - http://server/filenotpresent.php4
>     calls php before verifying if "filenotpresent.php4"
>     exists. So, instead of opening /404.html,
>     we got an internal error because
>     "/usr/.../bin/php filenotpresent.php4" returns
>     no data.
>
> My question :
> Is there is a way :
>  - to tell php to generate an HTML page containing a redirect
>    to /404.html, if the given file doesn't exists
> or
>  - configure Apache to force it to check if the
>    file exists before calling php ?
>
> Thanks for your help.
>
> Laurent.
> PS : I sent this email to php-install yesterday, but I didn't have
>      any answer.
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to