Main Menu

!!

Join over 140k discussions


Cokoye is an Africa-focused community with over 500k members where people freely ask questions.   Join FREE

Creating a Custom 404 Error Page

Started by Perfect, 2011-06-17 00:06

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Guest posting agency=

Perfect

Every surfer has found the dreaded 404 page not found error message.

The generic error page is horrible to look at and it does not encourage internet users to further explore your site.

Imagine being able to set up a page of custom error messages that looked good, he told the visitor what had happened and suggested some alternative links to other places in your site, such as the homepage, site map or a search page.

If the visitor wanted to, could visit other parts of your site.

It is very easy to set up a custom 404 error page (error 404 is the error number is returned when a page or directory is not in place).

The easiest way to redirect visitors to find a good 404 is sent to the sites of your home page or your page Sitemap

We do this by placing a line of code on their websites. Htaccess

ErrorDocument 404 / sitemap.html

This 404 redirect all error messages to the map page.

The path to the page you want displayed, and must exist on the web server, otherwise the Web server is tied into an endless loop.
The complete path to the error page must be specified and should be relative to the root path of that account (remember, placing a / before a filename or directory is specified to be relative to root directory).

To make a custom error page, just create a web page with your favorite editor like Microsoft FrontPage or Dreamweaver. The page can contain anything you want, including images, links, etc. Save the file as something easy to remember (eg 404errors.html)

Then I suggest you take a directory directly from your / public_html / folder and call it "error" and put the error files here.

This now means that the command line would look like htaccess now.:
ErrorDocument 404 / error/404errors.html

Now every time a 404 has been generated in your site, your custom error page is displayed and keep your website visitors happy.

In the next article, I extend this idea, and show you how you can be notified via email that a 404 has been in place. It will tell you the cause of the error and the offending page. Allowing you to try to fix all the broken links that lead to your site.



back link building services=