cancel
Showing results for 
Search instead for 
Did you mean: 

Custom Error messages...

N/A

Custom Error messages...

Can I/How do I make my own custom error messages for errors such as 404, 403, 401 etc etc...

Cheers
Will
6 REPLIES
benoh
Grafter
Posts: 272
Registered: 24-08-2007

RE: Custom Error messages...

> Can I/How do I make my own custom error messages for errors such as 404, 403, 401 etc etc...
>
> Cheers
> Will


Hi Will,
You need to use a .htaccess file to redirect to the file you want.

have a search on www.apache.org for the correct directrives, I believe its something like

ErrorDocument 404 /full/path/to/file.html

The full patch to files is as follows

/share/isp/plusnet/www/XX/username/htdocs

where XX= first 2 letters of your username.

Ben O'Hara
Network Support Analyst
PlusNET Technologies.
N/A

RE: Custom Error messages...

Thanks Ben,

By the way I gave up on that crontab I only ever managed to get it to work once and then nothing... but thanks for the help on that as well

Cheers
Will
N/A

RE: Custom Error messages...

Hi,

I've been thinking of creating my own 404s one day. i shall have to check this myself.

Thanks
Chris
--
| Chris Rugen ................................ Unmetered & ADSL solutions
| Customer Support................................... for Home & Business
| PlusNet Technologies Ltd ........................... http://www.plus.net
+ ---------- My Referrals - It pays to recommend PlusNet ---------------
N/A

RE: Custom Error messages...

Chris,

To save you some time...

put simply in the root directory for the web site (I presume actually in htdocs but could someone check) put a .htaccess file and in that have the lines

ErrorDocument 400 "This will display this text on screen
ErrorDocument 401 /path/to/file/file.htm
ErrorDocument 402 http://host.name.com/file/file.htm
ErrorDocument 403 "etc etc etc
ErrorDocument 404 "and so on for the rest of the errors

and the error codes are!

400 = bad request
401 = Authorization required
403 = Forbiden
404 = Page not found (aka 4 ohhh 4)
500 = Script failure (aka Server naffed up)

Cheers
Will
N/A

RE: Custom Error messages...

Thanks for the information!

I'll try this in a few weeks.

Thanks
Chris
--
| Chris Rugen ................................ Unmetered & ADSL solutions
| Customer Support................................... for Home & Business
| PlusNet Technologies Ltd ........................... http://www.plus.net
+ ---------- My Referrals - It pays to recommend PlusNet ---------------
N/A

RE: Custom Error messages...

> Thanks for the information!
>
> I'll try this in a few weeks.
>

Although you'll probably read this... heres something good for the dreaded 4 ohhh 4...

http://portal.plus.net/central.html?action=new_forums&forum_action=display_topic&topic_id=1262&displ...

Cheers
Will