[thelist] RE: Customising Error Messages

Simon Ould simon.ould at nortechcontrol.com
Mon Jul 23 10:03:26 CDT 2001


If you are using Apache then you can do this very easily using an htaccess
file (providing the "AllowOverride" setting in httpd.conf has been set to
let you)

Try reading this article:
http://evolt.org/article/A_Cheesy_htaccess_Tutorial/18/226/index.html

and/or looking at this page:
http://httpd.apache.org/docs/custom-error.html 

Or, if you can't be bothered to follow the links, then here's the concise
version: add the following line to your .htaccess file: 
ErrorDocument 404 /mypath/tothe/errorhandler/404.php
(With the relevant changes 404.php will get called instead of the usual
rubbish.)

I know that this could be a waste of time, bearing in mind that I don't know
what web server you are using, but I think that some people will find it
helpful. (hopefully)

Incidentally there is a surprising amount that you can do using an htaccess
file: my most recent discovery was how to get my ISPs web server so to parse
.html files as .php files.
<Files *.html>
ForceType application/x-httpd-php
</Files>

Search google.com for more info.

Regards,

Simon


> ----- Original Message -----
> From: <larshilstrom at oceanfree.net>
> To: <thelist at lists.evolt.org>
> Sent: Friday, July 20, 2001 5:06 AM
> Subject: [thelist] Customising Error Messages
> 
> 
> > Hi
> >
> > I want to customise the 404 error message so that visitors 
> see a more
> helpful
> > message instead. I know it can be done, but I'm not sure 
> how. Can anyone
> give
> > me any clues?
> >
> > Thanks
> > Lars Hilstrom
> >
> > Visit http://www.oceanfree.net to get your free e-mail 
> account and use our
> unique Irish Internet directory




More information about the thelist mailing list