Forum Moderators: phranque

Message Too Old, No Replies

404's

I like .hta

         

custom404

3:14 am on Jan 8, 2008 (gmt 0)

10+ Year Member



Hi. I am a new member. I introduced myself in the Community Center [webmasterworld.com ]

I am running Apache and like [custom] 404 [pages].

Will you show me yours? I love 404's...

[edited by: jdMorgan at 4:21 am (utc) on Jan. 8, 2008]
[edit reason] No URLs, please. See Terms of Service. [/edit]

jdMorgan

4:39 am on Jan 8, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hello custom404, and welcome to WebmasterWorld!

We don't allow posting of links to personal sites here, in order to discourage posting based on purely-promotional motives, to keep the signal-to-noise ratio high, and to protect our members and their sites.

Your custom 404 implementation is broken, and returns a 302-Found status. This may lead to duplicate-content and/or non-optimal spidering problems with search engines, and leaves your site vulnerable to malicious exploits intended to cause you such problems.

Check it yourself with the "Live HTTP Headers" add-on for Firefox and Mozilla-based browsers. An essential tool for the Webmaster, and easy to find with a search. Any request for a bad URL on your site results in a 302-Found status response -- Not good!

The most-common reason for this error is using a directive such as

ErrorDocument 404 http://www.example.com/custom-404.html

instead of the correct
ErrorDocument 404 /custom-404.html

As documented in the Apache core ErrorDocument documentation [httpd.apache.org], using a canonical URL instead of a local URL-path results in a 302-Found redirect response being generated instead of the desired 404-Not Found response. Since search engines take the server response literally, they will mark *any* URL in your domain as an existing page, leading to problems for your site.

A custom 404 page should have the following characteristics. It should:

  • Return a 404-Not Found status response.
  • Assume the reader clicked on a link somewhere leading to the non-existent URL -- Don't blame the user!
  • Be polite, professional, and helpful (hackers won't care, and most exploits are machine-generated anyway)
  • Contain a prominent link to your home page, site map, or site-search facility.
  • Contain a link to a relevant subject category (if you use a script and can infer this from the request)

    In addition to sleek visual design and effective navigation, a professional site should have all of its technicalities in order.

    Jim

  • custom404

    6:46 am on Jan 8, 2008 (gmt 0)

    10+ Year Member



    thank you Mr. Morgan (jd) -- I just revamped this site January 1st and the new design is a lot more professional than my previous.

    In the past, I was a plaything for my fellow webmaster, but I have grown a lot since then and wish to exhume a much more professional page targeted to attract business, not my fellow webmaster.

    Your comments are right on cue with my direction, and I appreciate the new things I learned from you. I am currently working to resolve many of the suggestions in your post.

    For example, tonight I logged in to my Google Webmaster tools and found the error you spoke about. Google said they could not verify my webpage and I was going to ask about what I read there [google.com ] since I did not (still a little cloudy) understand.

    From what you wrote, I'm pretty sure I need to go in to that hta and make that fix -- or at least check it and get back here after I know better what I did.

    Thank you again. I hope others here are as kind as you. I'll be back as soon as I can.

    custom404

    6:12 pm on Jan 14, 2008 (gmt 0)

    10+ Year Member



    I believe I fixed all of those thingies except: "Contain a link to a relevant subject category."

    Not really sure how to do that. Could you give me some search terms for me to begin my search/resolution?

    You can check my website because I have changed my 404.. much more professional now :o)

    jdMorgan

    9:06 pm on Jan 14, 2008 (gmt 0)

    WebmasterWorld Senior Member 10+ Year Member



    That's an option available if you use a script as your custom 404 page. The script can look at the client request variables to see if --for example-- the request was referred by a search engine. If so, the script can parse the HTTP_Referer variable and look for words that the visitor included in his/her search. If any of your pages or categories match some or all of those words, you can list those pages and let the visitor pick one.

    Similarly, if your pages are all well-named, you could select new existing page URLs based on the keywords in the missing page-names themselves, and present those for the visitor to pick from.

    Some sites have obvious categories, and some don't. Levels of organization and structure vary. We also don't do site reviews here, so this discussion is intentionally generalized... :)

    Jim