Watching:

File naming conventions


show more File naming conventions provides you with in-depth training on Web. Taught by James Williamson as part of the Dreamweaver CS4 Essential Training show less
please wait ...

File naming conventions

As you create files for the web, understanding the rules governing their naming is vitally important. If your files are not named correctly, certain pages might become inaccessible or just not work properly. Remember that web pages contain links to other web pages and the assets. If file naming isn't handled correctly, your sites functionality can really suffer. Fortunately the rules for File Naming Conventions on the web are pretty easy to follow. First, don't use any spaces in your file names. If you have a file that is longer than one word, use underscore or a hyphen to separate the words. Most web servers will allow file names with spaces but when the link is resolved the special character %20 can sometimes be used in place of the space. This is really messy and can lead to a lot of confusion when sending links or displaying URLs.

Second, shorten the filename if you can, rather than about_us.htm, how about just about.htm. Shorter names are easier to remember and makes URLs easier for clients to type. Next, avoid using special characters. No dollar signs, exclamation points, forward or back slashes, question marks, periods or really any other special character or punctuation. Many of these symbols are used to denote things like directory structure, URL parameters or other meanings that you could unwittingly trigger.

Numbers are okay to use in filenames. Just avoid using them as the first character. Also avoid uppercase letters if possible. Most web servers won't care but some unique servers are case sensitive and links could not be resolved correctly even as spelled correctly. When using extensions, just be consistent. For non-dynamic websites it's okay to either use .HTM or .HTML. To avoid having to worry about it you can set up a default extension in Dreamweaver's Preferences and Dreamweaver will resolve the extension for you.

If you stick to these rules when naming your files, you should avoid any errors or problems within your site.

File naming conventions
Video duration: 2m 1s 10h 15m Beginner

Viewers:

File naming conventions provides you with in-depth training on Web. Taught by James Williamson as part of the Dreamweaver CS4 Essential Training

Subject:
Web
Software:
Dreamweaver
Author:
please wait ...