.htaccess to Mask Errors on Your Website

The .htaccess file is a control file located in your webservers directory. This file is a very powerful file that can control access to certain files, restrict access to files, forward people in the event of errors, and many more useful features for webmasters!

One of the most embarrassing things for a webmaster is to have a website with dead links, bad URLs, and error messages when the user surfs through your website. Using the .htaccess file you can help reduce how noticeable those errors are by quickly moving the user to a correct working location. This method of course doesn't correct the underlying problem with your website, however it does help to keep your website looking more professional.

Common error codes that you want to try to hide from the user:

400 - Bad Request
401 - Authorization Required
403 - Forbidden
404 - Page Not Found
500 - Internal Server Error
501 - Not Implemented

The biggest and most common error by far is the 404 Error (Page not found), but all of these can be embarrassing and troublesome to webmasters. If an error occurs on your website you don't want to lose that user. You may not be able to provide them with a link to the page they wanted, but you might get another chance if you redirect them to another page within your website.

Syntax for .htaccess file:

ErrorDocument ### index.php -- Example of format
ErrorDocument 404 /index.php -- Working example

In the second example, should a user request a page that no longer exists on your website, they will automatically have the index.php file loaded. This can be done for all of the error codes listed above and will help to hide and glaring mistakes in your website.

As I mentioned before, this is not a fix action for your website, but simply a mask. It's very important to review your website logs and look for error codes. The goal is to have a good working website afterall!

Ken Dennis
http://KenDennis-RSS.homeip.net/

In The News:


pen paper and inkwell


cat break through


Got Web Traffic but Still Low Sales? Ten Ways to Selling Success - Part 1

Have you put a lot of effort, time, and money... Read More

Content - the Key to Long Term Success

Every day internet marketers are inundated with the latest fad... Read More

Do You Hate Your Website? Web Site Sales To Hit $316 Billion Over The Next 6 Years

What dollar amount does your web site contribute to this... Read More

How Not to be Ripped Off by Your Website Designer

As web designer my self, I have had the unfortunate... Read More

Click Here

See, works every time. Seriously now, for some reason people... Read More

The Golden Rule Of Website Building

Copyright 2005 Robert EvansSetting yourself up to earn a steady... Read More

How Not To Get Web Design Work

I get the occasional web design lead from my website.... Read More

Is Your Website?s Copy Up to the Mark?

The Internet is a relatively new medium. What works for... Read More

Web Site Professionalism? What Is It?

Your web site should be-visitor friendly to navigatesearch engine friendly... Read More

Website Creativity: Why It Matters Now More than Ever

If one more business owner tells me their website sucks... Read More

Becoming A Website Designer

The ability to create simple, attractive and functional web pages... Read More

Flash Web Design - The Wave of the Future?

There are two camps when it comes to flash web... Read More

Your Website Could be Letting You Down

A professionally presented business website is a powerful and essential... Read More

Sell Yourself First...Your Key To More Sales

Selling on the internet is a challenge. There is no... Read More

The Ultimate Web Site Marketing Strategies That You Should Know

Most of us know that we need to advertise our... Read More

Save Time and Boost Profits with Free Content

Public domain gives you a head start creating ebooks, ecourses,... Read More

Event Planning Must Include An Event Website

As part of your event planning you should seriously consider... Read More

Top Ten Website Design Secrets for Internet Marketing Success

When it comes to marketing your website, you should really... Read More

10 Profitable Ways To Recycle Your Content

1. Repackage your web site content in to different products... Read More

Understanding How HTML Color Codes Work

Ever wonder how HTML color codes are put together? For... Read More

Elements of Graphic Design for Your Website

We've all seen them. Poorly designed web sites that make... Read More

Creating Personal Web Sites (Part 2)

This is the second part of a two-part article about... Read More

How to Create a Favicon for Your Web Site

One of the simplest things you can do to give... Read More

Concentrate On Web Content Instead Of Search Engine Optimization

For many webmasters the title of my article may seem... Read More

To Hire or Not to Hire a Website Designer

In the early years of the internet the actual design... Read More

The Secrets of The Shriekers

I am constantly bombarded with all sorts of advertisements, single-page... Read More

Quality Website Design At An Affordable Price

I always have people asking me if I know of... Read More

Shameless Flashers - Using Flash Tools To Create Spectacular Websites

Flash is a powerful technology that can help you create... Read More

Welcoming Your Website Visitors

Imagine you're going on a blind date. You've heard wonderful... Read More

Tableless Web Designs: Why I Switched

Since I made the switch 6 months ago to a... Read More

Website Savvy: 10 Key Steps to Turn Your Customers ON!

"How to turn "slightly interested" customers into "I've got to... Read More

Pop-Ups Still Work. At Least For The Time Being

Do you remember playing with the jack-in-the-box toy as a... Read More

How to Convince Your Visitors to Return Often

One visit does not make a sale. Be sure to... Read More