Killersites.com Homepage Welcome Guest   |   Register  |  Login
Login Name Password
  Search  
  Index  | Recent Threads  | Unanswered Threads  | Who's Online  | User List  | Help



Quick Go »

No member browsing this thread
Thread Status: Active
Total posts in this thread: 14
Posts: 14   Pages: 2   [ Previous Page | 1 2 ]
[ Jump to Last Post ]
Post new Thread
Author
Previous Thread This topic has been viewed 12106 times and has 13 replies Next Thread
Male Richard_Conyard
Stranger




Joined: Jun 16, 2005
Post Count: 6
Status: Offline
Reply to this Post  Reply with Quote 
Re: TIP: CREATING A CUSTOM 404 PAGE

I'm already using a custom 404 page, but wish to capture any HTTP POSTed input to the page. This doesn't seem to be returned as standard, does anyone know how I can capture this?
----------------------------------------
http://www.thinkcolony.com
[Jun 16, 2005 5:21:21 AM] Show Printable Version of Post    View Member Profile    Send Private Message    Hidden to Guest [Link] Report threatening or abusive post: please login first  Go to top 
Male Fidget
Newbie
Member's Avatar


Joined: Jun 16, 2005
Post Count: 27
Status: Offline
Reply to this Post  Reply with Quote 
Re: TIP: CREATING A CUSTOM 404 PAGE

A lot can depend on your type of hosting, or your own host's configurations - as the OP says, sometimes, its easier to just ask them.

Most apache servers are configured (by default I believe) to look for a (in this case) 404.shtml document in your public html folder. The reason for the use of an shtml page is to allow for the return of header information such as referrers, page requested, etc. Those variables usually include ...

Referring URL - <!--#echo var="HTTP_REFERER" -->
Visitor's IP address - <!--#echo var="REMOTE_ADDR" -->
Requested URL - <!--#echo var="REQUEST_URI" -->
Server Name - <!--#echo var="HTTP_HOST" -->
Visitor's Browser - <!--#echo var="HTTP_USER_AGENT" -->
Redirect Status Code - <!--#echo var="REDIRECT_STATUS" -->

Its worth noting though - any URLs used in a 404 or other error document (including references to graphics, etc) should use absolute paths since the document can be produced from anywhere in your site. Failure to do so, or use relative paths can merely lead to another 404 and another and so on.

I am a firm believer in a site map for a 404, or other error document (such as 400, 401, 403 and 500, since errors can occur for other reasons that are not the fault of your site's content) and, if you can do it, a means of search, just as the OP recommends. There are some free search scripts about the internet, both CGI and PHP based (ksearch seems to ring a bell without conducting my own search for one, and is more useful if you cannot use PHP or MySQL since it builds a search database in a flat file format).

Another thing to donsider is what sort of web hosting control panel you have, the popular ones such as cPanel, H-Sphere and Plesk offer a simple facility to create your own error pages using your own HTML and simply upload them via the control panel.
[Jun 19, 2005 6:57:52 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Male webreviews
Stranger




Joined: May 7, 2007
Post Count: 6
Status: Offline
Reply to this Post  Reply with Quote 
Re: TIP: CREATING A CUSTOM 404 PAGE

Thanks for this idea! That will be so useful. Our website is using PHP server and the extension is case sensitive. Our website had originally /eCommerce-Website-Design.php kind of upper/lower format for readability and too many people were typing it in wrongly and getting 404 errors. Then we renamed the links to all lowercase like this:
http://www.wspgweb.com/ecommerce-site-design-development.php
and started getting thousands of 404 errors.


One other idea is to have your sitemap on your 404 error page. That way the viewer can go to the page that they want to go to.
----------------------------------------
[Edit 3 times, last edit by webreviews at May 10, 2007 10:41:18 PM]
[May 10, 2007 10:36:45 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Female Susie
Advanced Member
Member's Avatar

Ohio, USA
Joined: May 30, 2004
Post Count: 2677
Status: Offline
Reply to this Post  Reply with Quote 
Re: TIP: CREATING A CUSTOM 404 PAGE

One good idea is to take your site-map page, and make it the 404 page for your website. Another idea would be to make your 404 page a search page where people could search your site.

I took this quote from Stef's original post. smile
[May 11, 2007 5:02:15 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Posts: 14   Pages: 2   [ Previous Page | 1 2 ]
[ Jump to Last Post ]
Show Printable Version of Thread  Post new Thread