<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
    <HTML>
    <HEAD>
    <TITLE>Easy HTML Construction Kit: Code to HTML</TITLE>
    </HEAD>
    
    <BODY BGCOLOR="#BEE7FF" TEXT="#000000" LINK="#0000FF" VLINK="#6E00FF" ALINK="#FF4CBD" background="../backg/marb.jpg">
    <font face="Trebuchet MS,Arial,Tahoma,Verdana,Sans-serif,Helvetica">
    
    <CENTER><P align=center><TABLE border=6 cellpadding=6>
    <TR><TH><font size="+2">Code to HTML</font></TH></TR>
    </TABLE></P></CENTER><P>
    
    <BLOCKQUOTE>
    
    This utility is for converting program code (e.g. C or HTML) in a textfile to a HTML document.  This panel initially appears as follows:<P>
    
    <center><img src="c2h/c2h01.gif" width="744" height="376"></center><P>
    
    Programming languages such as C use characters which require special HTML codes in order to be displayed correctly, including:
    
    <CENTER><TABLE cellspacing=12 border=0>
    <TR><TD align=center><TT>&lt;</TT></TD><TD align=center><TT>&gt;</TT></TD><TD align=center><TT>&quot;</TT></TD><TD align=center><TT>&amp;</TT></TD></TR>
    <TR><TD align=center><TT>&amp;lt;</TT></TD><TD align=center><TT>&amp;gt;</TT></TD><TD align=center><TT>&amp;quot;</TT></TD><TD align=center><TT>&amp;amp;</TT></TD></TR>
    </TABLE></CENTER>
    
    Also, if one wishes to display HTML code within an HTML document, these characters must be converted to their corresponding codes.
    
    It is thus not sufficient, when displaying program code in an HTML document, to enclose it in <font face="Courier,Courier New,Mono">&lt;PRE&gt;...&lt;/PRE&gt;</font>.<P>
    
    <I><B>Code to HTML</B></I> automates most of the tasks involved in converting program code to a decent-looking HTML document.  Sometimes some editing will be required to get the HTML document into its final form (e.g., splitting long lines into two or more lines), but this tool should be able to do most of the work.<P>
    
    <HR><P>
    
    The file containing the program code to be converted, and the file to contain the resulting HTML code, are specified in the usual way (as explained in <A HREF="txt2h.htm#example">Text to HTML</A> and in <a href="templ.htm#newfile">HTML Template</a>).<p>
    
    The  converted program code is placed between a standard header and footer as follows:<P>
    
    <PRE><FONT FACE="Courier,Courier New,Mono">    &lt;html&gt;
        &lt;head&gt;
        &lt;title&gt;<I>program_source_code_filename</I>&lt;/title&gt;
        &lt;meta name=&quot;ROBOTS&quot; content=&quot;NOINDEX&quot;&gt;
        &lt;/head&gt;
        &lt;body bgcolor=&quot;#FFFFFF&quot; text=&quot;#000000&quot;&gt;
        &lt;pre&gt;
    
        <I>Converted program source code goes here.</I>
    
        &lt;/pre&gt;
        &lt;/body&gt;
        &lt;/html&gt;</FONT></PRE><P>
    
    
    This is what the <A HREF="c2h/this_doc.htm">HTML source for this document</A> looks like when viewed with a web browser.<P>
    
    <CENTER>
    <P align=center><TABLE border=4 cellpadding=8>
    <TR>
    <TD align="center" colspan=2><A HREF="ehck.htm">Easy HTML Construction&nbsp;Kit</A></TD>
    <TD align="center" ><A HREF="../index.php">Home&nbsp;Page</A></TD>
    </TR>
    </TABLE></P>
    </CENTER>
    
    </font>
    </BLOCKQUOTE>
    </BODY></HTML>