Jump to content
xisto Community
Sign in to follow this  
GeT HeXD

404 Error Page Learn to make a really cool one

Recommended Posts

First, you should know a little bit of basic PHP. It is relatively simple.

<?phpecho $_SERVER['HTTP_USER_AGENT'];echo $_SERVER['REMOTE_ADDR'];?>

echo $_SERVER['HTTP_USER_AGENT']; - Displays users browser.
echo $_SERVER['REMOTE_ADDR']; - Displays users IP Address.

If you have a PHP host, put in
<?phpphpinfo();?>
and in one of the sections, there are a whole bunch like these. Like display where user came from etc. Experiment...and you can create something like

Hey! What are you trying to do, buddy?! I know you are using Microsoft Internet Explorer! Your IP is 192.168.0.0! So don't keep trying or we will hunt you down and hack you!

for a 404 Error Page. Oh boy!

-HeXatorials

Share this post


Link to post
Share on other sites

Additional Information on Configuring the .htaccess so as to define the custom error pages. You can either do by the following way or login to your Cpanel and use the custom error page tool to configure the .htaccess file automatically.

For sites hosted on the Linux cluster, you must create a .htaccess file and upload it to your www directory. You will also need to write the custom error pages and upload them to your site.
The .htaccess file is used to override a default setting within the configuration of Apache. The syntax for the .htaccess file is as follows:

ErrorDocument errorcode path-to-page

A working example:
ErrorDocument 404 /custom/404.php


Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.