Actually, it's not. The problem is that most of the time, developers don’t even realize that they’re needlessly taxing their server (even if it’s just a little bit).
Let’s look at an example link:
Code:
http://somesite.com/subdirectory
This appears to be good; you’ve got your
http://, you’ve got your URL, and everyone’s happy, right?
Right?
Not entirely. The process goes a little something like this, depending on your server and setup:
Browser: Give me ‘subdirectory.’
Server: Just a minute; first I’ll try to find a file called ‘subdirectory.’ ... Wait a second; it’s not there! How about a directory called ‘subdirectory?’ ... Ah, here we go. Okay. And next time, please use a trailing slash.
Browser: Roger that.
But by changing our link just a little bit:
Code:
http://somesite.com/subdirectory/
...everything becomes hunky dory. The server won’t have to guess whether ‘subdirectory’ is a subdirectory or a file; it will know.
Why should we bother? Because:
- We’re doing ourselves a favor, as this is the correct way to do things.
- We’re doing our server a favor, as this means less disk access, less bandwidth, and less load on the server.
- And most importantly, we’re doing our visitors a favor because they’re no longer losing a few seconds while our server tries to find first a file and then a directory. And in this industry, you and I both know that a few seconds is a long, long time.
You can search Google for more information on this topic, but here is one article that I found:
http://www.nicemice.net/amc/soapbox/directory-URLs.var
I hope this helps.