How to set up Custom Error pages

1
friends here is a tutorial on how to setup custom error pages on your website like forum or blog



  1. make a text file
  2. name it .htaccess
  3. Save File Type as "All Files"
  4. Open it With Notepad
now type this code there





Code:
<Files ~ "^\.(htaccess|htpasswd)$">deny from all</Files>ErrorDocument 400 /400/error.phpErrorDocument 401 /401/error.phpErrorDocument 402 /402/error.phpErrorDocument 403 /403/error.phpErrorDocument 404 /404/error.phpErrorDocument 405 /405/error.phpErrorDocument 406 /406/error.phpErrorDocument 407 /407/error.phpErrorDocument 408 /408/error.phpErrorDocument 409 /408/error.phpErrorDocument 410 /410/error.phpErrorDocument 411 /411/error.phpErrorDocument 412 /412/error.phpErrorDocument 413 /413/error.phpErrorDocument 414 /414/error.phpErrorDocument 500 /500/error.phpErrorDocument 501 /501/error.phpErrorDocument 502 /502/error.phpErrorDocument 503 /503/error.phpErrorDocument 504 /504/error.phpErrorDocument 505 /505/error.phporder deny,allow

now save it


now that your file is ready. , where to place it in order to make it affected to the website


For Wordpress : place it in "public_html/wp/"


For Mybb : Place it in " public_html/mybb/"




Note: if you get popup called .htaccess already exist just over write it


you can edit path to error file by


Example:

the path is marked in red color in the example , you can edit to the path to your new error file



ErrorDocument 400 /400/error.php


Thanks ,

happy erroring
Smile

ssparikshya Smile
[Image: An9XX.gif]
Happy Erroring what is this
[Image: An9XX.gif]

    How to set up Custom Error pages