“The perfect PHP script for effectively managing most website error documents!”
Author : James Anderson Jr. (Contact : [ click here ] ; Web : https://www.jamesandersonjr.com)
Website : https://www.perfecterrordocs.com
Download Address : https://www.perfecterrordocs.com/download/
License Address : https://www.perfecterrordocs.com/license/
Demo Address : https://www.perfecterrordocs.com/demo/
Copyright © 2024 James Anderson Jr.
This file is part of the “Perfect Error Documents v.5.x.x” online script.
“Perfect Error Documents” (“PED”) online script is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the full “PED” license agreement at [ https://www.perfecterrordocs.com/license/ ].
You should have received a PDF copy of the license agreement, along with your download of the “PED” online script. If not, please visit [ https://www.perfecterrordocs.com/license/ ], for your free copy.
For support, and all other inquiries, please feel free to email us at: cs [at] perfecterrordocs [dot] com.
Web Server : Apache 2.x (or later) hosted on UNIX/Linux
PHP : PHP 5.4.x (or later)
Database : Not Required
-
Unzip the downloaded ‘PerfectErrorDocuments.zip’ (‘PerfectErrorDocuments-master.zip’ on GitHub) web package contents into an off-line repository of your website, with the ‘error-documents’ folder being a direct sub-directory of the root of your website’s tree. (e.g., ‘/public_html/error-documents/’ )
-
Open ‘config.php’ located inside ‘/error-documents/config/’ folder, with your favorite HTML/PHP code editor (Notepad++ is highly recommended).
-
Locate, and update line | 37 |, as shown below, to the actual location of your webmaster’s contact page.
37 |$wbmstr_lnk = '/contact-webmaster.php';
(e.g., $wbmstr_lnk = '/contact-wm.php';)
Side Note: | This can be a relative URL, a root-relative URL (as shown above), an absolute URL, or a
'MailTo:'email link. Just make sure it points to the correct location of your webmaster’s contact info.
- Locate, and update line | 41 |, as shown below, to include your ‘Facebook App ID’, if you have a ‘Facebook App’. If not, you can create one here.
41 |$fb_app_id = '';
- Locate, and update line | 43 |, as shown below, to include your ‘Facebook Page ID’, if you have a ‘Facebook Page’. If not, you can create one here.
43 |$fb_pg_id = '';
Side Note: | You must be signed into an active Facebook account, in order to create a new ‘Facebook App’, or a new ‘Facebook Page’.
- Locate, and update line | 47 |, as shown below, to include your ‘Twitter’ username, if you have a ‘Twitter’ account for your website. If not, you can create one here.
47 |$twtr_usrn = '';
Side Note: | All of the social media account PHP variables, such as
$fb_app_id,$fb_pg_id, and$twtr_usrnwill gracefully fallback to PED’s own default social media account information, if you do not enter any overriding values of your own (So, if you skip steps (4-6), and you decide to leave one, or more, of them blank, it won’t break anything).
- Locate, and update line | 51 |, as shown below, to include your websites current locale. Use the format:
'language_TERRITORY'. For a list of valid locales, visit: [ https://fbdevwiki.com/wiki/Locales ].
51 |$locale = '';
-
Save, and close, the ‘config.php’ file.
-
Upload the entire ‘error-documents’ folder into the root directory of your website (usually the ‘public_html’ directory).
Side Note: | For ‘add-on domains’ and ‘subdomains’ usually not accessed directly under the web server’s primary root directory (e.g., ‘public_html’), please relocate the ‘error-documents’ folder into the directory that your ‘add-on domain’ or ‘subdomain’ points to, in order to use the script for that website.
- Finally, add the below lines of code, into your ‘.htaccess’ file, in the root directory of the same website you intend to deploy the “PED” script (See previous ‘Side Note’ ). If you don’t have an ‘.htaccess’ file, already, you will need to create one, now.
# ###################---Specify Error Documents---################### #
# Error - [401] Unauthorized
ErrorDocument 401 /error-documents/error401.php
# Error - [403] Forbidden
ErrorDocument 403 /error-documents/error403.php
# Error - [404] Not Found
ErrorDocument 404 /error-documents/error404.php
# Error - [500] Internal Server Error
ErrorDocument 500 /error-documents/error500.php
# ################################################################### #That’s it! Your new installation of the ‘PED’ online script is now complete.😃👍
Congratulations on obtaining, and installing your personal copy of the ‘PED’ online script.👏
💡 Remember: | For support, and all other inquiries, please feel free to email us 24/7 at: cs [at] perfecterrordocs [dot] com.
💡 Remember: | 100% voluntary donations are currently being accepted through our Official Website at [ https://www.perfecterrordocs.com/donate/ ]. We would surely appreciate your support! ❤