Most websites maintain a relatively simple format compared to many commercial sites. Part of the reason is the need to retain a straight-forward easy-to-maintain modus operandi. The emphasis is on content, not bells and whistles.
Don't try to write your content in an HTML editor. All the code tags can blind you to spelling errors and other problems. Use a word processor, which have a variety to tools for improving your writing (thesaurus, spell checker, grammar checker, etc.). When ready, insert the text in the HTML page with copy-and-paste and then apply the HTML coding. In most cases, using the word processor's HTML conversion feature will only complicate your life. See our section of document conversion.
All web pages have two areas which appear at the top and bottom of each page:
- Flag: There should be links to the main page, a master site index, a search page if your site is big enough to warrant them. Usually this is in a single navigation bar at the top of the page.
- Administrivia: There should be a mention of the page location in the site, the date of the last modification of the page and the maintainer of the page, usually with am e-mail link. The maintainer is usually the project director. Most pages also place another set of the text navigation links at the bottom.
Set up a project template(s)
Most of your web pages will contain the same general format. Save yourself a lot of work and create a model page that has the boilerplate (heading, formatting, and other items). This tactic will also cut down on HTML errors. Don't bother to insert fonts tags on your text unless you use Cascading Style Sheets. It's just too much work to maintain.
Improving search engine relevance
Use the heading tags (
<h2> to provide structure to your text. Search indexers (Altavista, Google, etc.) go through your documents and use the headings to determine content. Descriptive titling can improve your showing in the search engine indexing.
Insert the page title in the
<title tag at the top of each pagen as the first metatag after the opening
<html> tag. Make it a descriptive title that identifies the page content. This is the most important touch for search engine indexing. You may also want to make changes to the meta tags for site description and keywords providing details from the page content.
Good HTML coding habits
Always close your block tags.
<p> </p> <ul></ul> <li></li>. This is important for new XHTML standards. It is also a requirement for the cascading style sheet to work correctly
Enclose all attribute values in commas ("").
Use the comment tag
If is a good practice to use the comment take
<!-- --> regularly in your documents, especially if your HTML coding has unusual features or specific purposes. Since project staffing, especially interns, can change frequently, annotating the document can save you from problems later.
Checking spelling, HTML code and links
Be sure to do a spell check when you're done with the page. Also double check the hyperlinks. Validate your HTML code with a program for that purpose or go to an online service. See the Web Development page for more details. Don't forget to run the validators on the templates.
File naming conventions
It is wise to use lower case for filenames (text and graphics) and directories. Do not use spaces in the name either; instead, use the underscore character ( _ ). You may want to use a UNIX server, which is case sensitive. Avoid complications: keep all file names lower case.
A good filename convention is that only index pages of each folder (in other words, the default page if a visitor goes to a subsite: http://www.domain.org/project_name/) use the .html extension, given the extent to which Windows has difficulty keeping track of the difference between the two htm and html extensions. All other files should have the .htm extension.
Make sure it works
After you have uploaded your page to the site, try to open the page and make sure that it works. Also check the links -- again. If you have graphics, be sure that they appear. Sometimes you may need to make small changes (absolute URLs rather than relative URLs). Unix also requires you to set the attributes for the file or directory (that is, specify how a visitor can use the file or directory). Depending on your FTP program, this may be done automatically. In other cases, you have to set the attributes manually.
With a Unix server, all directories should have the setting 755 (a visitor see what's in a directory but not rename, remove or add files) and all files should be set to 644. This is known at the CHMOD command in Unix.
Backup your site
After uploading files to the web server, you should be sure to keep a version of the page on your own computer/server so that you can use it as a working draft. You should back this version up periodically. There are kinds of cases of web professionals, who should know better, losing their web pages because of a catastrophe on their sites. If it can happen to them, it can happen to you.