[Tutorial] How to create a custom 404 Error page 11-12-2012, 02:46 AM
#1
This tutorial will walk you through the steps of how to create a custom 404 Error page for your website. If you don't know what that is, here is an explanation: A 404 Error page is basically the page that comes up when you try to visit a part of a website that does not exist. Example: http://mxlitary.com/sadfhualshgoihawesdg.../sfda/fsda
___________________________________
The Steps
1. Go to your 'public_html' folder
2. Find the '.htaccess' file
3. Download the file and open it up with notepad or any other program that will let you view the file. Normally, there should be nothing in it.
4. Type this in it exactly:
5. Save the file and upload it back to where it originally was replacing the original '.htaccess'
6. Create a file and name it 'filenotfound.php'
7. Now, you may edit the file as if it were any other .php file. Remember though, this will be what shows up as your 404 Error page. You may want to put something along the lines of, "We could not find the page you were looking for," with a link back to the homepage.
8. Upload the 'filenotfound.php' into the main directory for your website.
9. Test it. Type this into your URL bar: http://YOUR_SITE.com/iwrgodhnasioweaagjki/adfs/dasf/
(Anything will work)
10. Enjoy your new custom 404 Error page.
___________________________________
The Steps
1. Go to your 'public_html' folder
2. Find the '.htaccess' file
3. Download the file and open it up with notepad or any other program that will let you view the file. Normally, there should be nothing in it.
4. Type this in it exactly:
Code:
ErrorDocument 404 /filenotfound.php5. Save the file and upload it back to where it originally was replacing the original '.htaccess'
6. Create a file and name it 'filenotfound.php'
7. Now, you may edit the file as if it were any other .php file. Remember though, this will be what shows up as your 404 Error page. You may want to put something along the lines of, "We could not find the page you were looking for," with a link back to the homepage.
8. Upload the 'filenotfound.php' into the main directory for your website.
9. Test it. Type this into your URL bar: http://YOUR_SITE.com/iwrgodhnasioweaagjki/adfs/dasf/
(Anything will work)
10. Enjoy your new custom 404 Error page.




![[+]](https://sinister.li/images/modern/collapse_collapsed.png)


![[Image: eAwhVeW.png]](http://i.imgur.com/eAwhVeW.png)