ChildNet HTML Coding Standard
Policies
Procedures
Resources
Help
Children's Guidelines
Notification Form
Getting Started
Setting Up a Site Map
Writing Style Guide
Design Style Guide
Branding & Identity
Graphics Guidelines
Graphics Best Practices
Photography
Page Design Guidelines
Page Design Best Practices
Screen Resolution
Template Overview
Template Dimensions
Template Types & Details
Stylesheet Glossary
Coding Standards
Site Navigation
The following are examples of good HTML coding techniques to follow. Note: Font tags are not used anywhere. Classes are used instead to define a fonts attributes. This enables the webmaster to later update the Cascading Style Sheet and all pages through the intranet will take on the change.

Note: The code below both looks the same in the browser, see how much simpler the "Good Code" sample is.

Bad Code Sample
<TABLE border="0" cellspacing="0" cellpadding="3" width="100%"> <TR valign="top" align="left"> <TD><B><FONT color="#0033CC" size="+1" face="Arial,Helvetica,Univers,Zurich BT">Resources<BR></FONT><FONT size="-1" face="Arial,Helvetica,Univers,Zurich BT"></FONT></B><FONT size="-1" face="Arial,Helvetica,Univers,Zurich BT">The resources page on ChildNet may contain links to external sites. When you click on external links, a new browser window will open to another site which Childrenīs neither endorses nor controls</FONT><br><br></TD> </TR> </TABLE>

Good Code Sample
<TABLE border="0" cellspacing="0" cellpadding="3" width="100%">
    <TR>
        <TD class="pagetitle">Resources</TD>
    </TR>
    <TR>
        <TD class="copy">The resources page on ChildNet may contain links to external sites. When you click on external links, a new browser window will open to another site which Childrenīs neither endorses nor controls</TD>
    </TR>
</TABLE>

Tips:
1. Create a unique table row for each type style.
2. The simple class="copy" code replaces all of the font tag nonsense.
3. The class tag above can be used within any of the following tags:
<TD class="copy">
<TR class="copy">
<span class="copy">
<P class="copy">
<A class="copy">
All text defined within these tags will display using the attributes of the class defines. For a list of all classes available in the style sheet look at the Style Glossary.