File Names

When building web pages using HTML, file names become very important. Things to keep in mind when naming them:

1. Pick a format and stay consistent with it. Stick with lowercase letters. As the web moves toward XHTML, the format becomes more important, and lowercase letters work the best. Remember that the file extension is just as important as the name itself.

Good Examples index.html index.htm Bad Examples Index.HTML INDex.HTml index.HTML

2. Decide whether or not you are going to use "HTML" or "HTM". And stay consistent!!

3. Do not put spaces in your file names. Firefox and Internet Explorer react differently to spaces, and it may cause problems with your page or your graphics. If you want to use a complex name, separate the words with an Underscore. Unix servers will not allow spaces at all.

Good: page_one.html Bad: page one.html

4. Do not use unusual characters in your file names. You're safe with an underscore, but don't use other characters. Some of the characters have different meanings in HTML and can't be used as part of a name.

Bad Examples: page#1.html page*1.html page&^1.html

5. Follow the same rules when naming your graphic or multimedia files!!

Good: index.html picture.gif sound.avi

6. When uploading your pages to the WWW, most sites insist that the first page of your web site be named "index.htm" or "index.html". It's a good habit to use this for all the pages you build.

Home