Creating A Custom Error 404 Page

      What happens when someone types your website’s URL? What happens if they were to write something like this: yourwebsite.com/abou when they’re supposed to write this: yourwebsite.com/about? What happens when they type in a page that doesn’t exist on your domain? They would see a error 404 page, which tells them that what they wrote is incorrect. You most likely have seen one yourself, if you’ve mistyped a URL.

      Your website builder sometimes might automatically create an error 404 page for you, like this:


      Here’s another example:

      In Google’s case, there’s a robot who is sad because he’s broken into several pieces. The point is clear: Something’s wrong. You should create a custom error 404 page so that your website’s logo appears like Google.
      And here’s another website’s custom error 404 page:


      “So how do you create a custom error 404 page?” You might ask. Read on, to find out how to do so! Note, though, that these instructions may only work with 000webhost.
      First, login to your account at 000webhost. Once logged in, visit your website’s control panel. As shown in How Kids Can Build A Website For Free | Part 2 of 4 enter your file manager. In your public_html folder, create a new file. Name it .htaccess. Then, write this in the html box:

ErrorDocument 404 http://yourwebistedomainnamehere.com/error.html

      Obviously, replace “yourwebsitedomainnamehere” with your own website’s domain. Then, when you’re done, save your work, like this:


      After that, press the arrow next to the save button. Now create a new file. Call it error.html. Below is an example of code I created which you can copy and paste in the html box:

<html>
<body>
<style type=”text/css”>
body {
font-family: Arial;
}
</style>
<center>
<img src=”http://www.yourwebsitehere.files.wordpress.com/2011/11/downtown
.jpg” width=”800px”>
<br>
<h1>Whoops! 404! That’s an error. </h1><br>
That page you’re looking for might’ve been deleted, moved, or perhaps you mistyped it. Why don’t you go back to the <a href=”http://www.yourwebsitehere.wordpress.com”>homepage?</a><br&gt;
</center><br>
</body>
</html>

      Be sure to edit that code, using the help of Lissa Explains It All. You want your own logo, and a link to your own website, right? When you’re done, save your work.

      It’s that easy! You’re done creating your custom error 404 page!

      If you’re still confused, the 000webhost forum might be able to help you.

Advertisements