<HTML><!--This file created 8/11/98 11:43 PM by Claris Home Page version 3.0--><HEAD>   <TITLE>Writing Web Pages</TITLE>   <META NAME=GENERATOR CONTENT="Claris Home Page 3.0">   <X-CLARIS-WINDOW TOP=140 BOTTOM=480 LEFT=24 RIGHT=554>   <X-CLARIS-TAGVIEW MODE=minimal></HEAD><BODY BGCOLOR="#62D6AC"><CENTER><FONT FACE="Helvetica"><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=6 WIDTH="90%">   <TR>      <TD WIDTH="100%" BGCOLOR="#EEEEEE">         <H1><FONT FACE="Helvetica">WRITING WEB PAGES</FONT></H1>                  <P><FONT FACE="Helvetica">Although your Personal Data         Sharing is delightfully simple to use, it's also quite         powerful for a PDA program. You have the option of serving         up plain text notes, mixed HTML/plain-text notes, or         </FONT><A HREF="#rawHTML"><FONT FACE="Helvetica">raw         HTML</FONT></A><FONT FACE="Helvetica"> code. In addition,         you have the ability to now provide a </FONT><A HREF="custom.html"><FONT FACE="Helvetica">custom         default page</FONT></A><FONT FACE="Helvetica"> for your         Notepad Server.</FONT></P>                  <H2><FONT FACE="Helvetica">THE BASICS:</FONT></H2>                  <OL>            <LI><FONT FACE="Helvetica">Create a folder in your            Notepad called "<B>Web</B>" then write or file any number            of text-only notes in this folder.</FONT></LI>                        <LI><FONT FACE="Helvetica">Or, you can install <B>Notepad            Setup</B>, which will ensure you have a proper "Web"            folder and install two example Notes in that folder            (index.html and About Personal Data Sharing)</FONT></LI>                        <LI><FONT FACE="Helvetica">Name each note, following            these rules:</FONT>                        <OL>               <LI><FONT FACE="Helvetica">Make sure the names of the               notes contain </FONT><FONT FACE="Helvetica" COLOR="#FF0000">none               of these characters<BR>               </FONT><FONT SIZE="+1" FACE="Helvetica"><B>? / , " : +               &gt; &lt;</B></FONT></LI>                              <LI><FONT FACE="Helvetica">Don't name any note except               for a </FONT><A HREF="custom.html"><FONT FACE="Helvetica">very               special</FONT></A><FONT FACE="Helvetica"> one               </FONT><FONT FACE="Helvetica" COLOR="#FF0000"><B>"index.html"</B></FONT></LI>                              <LI><FONT FACE="Helvetica">The file name parser uses               the </FONT><FONT FACE="Helvetica" COLOR="#FF0000"><B>first               word of each note title </B></FONT><FONT FACE="Helvetica">as               the virtual filename. Select distinct names for your               notes keyed by the first word of the title.<BR>               <B>Example</B>: "My Server" and "My Cat Farm" both               evaluate to "My" in a URL request. Either change the               name of one note or do concantenate the words using an               underline character like so "My_Server" and               "My_Cat_Farm"</FONT></LI>            </OL>            </LI>                        <LI><FONT FACE="Helvetica">Now, if you want to            </FONT><A HREF="#advancedTopix"><FONT FACE="Helvetica">do            fancy stuff </FONT></A><FONT FACE="Helvetica">with your            notes, read on. Otherwise, </FONT><A HREF="serve1.html"><FONT FACE="Helvetica">go            try it out!</FONT></A></LI>         </OL>                  <H2><FONT FACE="Helvetica"><A NAME=advancedTopix></A>ADVANCED         TOPICS:</FONT></H2>                  <H3><FONT FACE="Helvetica">Spicing Up Your Notes with         Embedded HTML Tags</FONT></H3>                  <P><FONT FACE="Helvetica">Since the server basically takes a         note and encapsulates it in a HTML frame, you can add         hyperlinks and HTML formatting within your served notes         (without having to do </FONT><A HREF="#rawHTML"><FONT FACE="Helvetica">full         blown HTML</FONT></A><FONT FACE="Helvetica">) in order to         spice up the pages a bit. For instance, in your Note about         your car, you could reference a picture of it stored         somewhere else by writing </FONT><FONT FACE="Helvetica" COLOR="#330099"><TT>&lt;IMG         SRC="http://my.other.site.com/username/images/mycar.gif&gt;</TT>         </FONT><FONT FACE="Helvetica">and when your Notepad page is         served up, the browser will run off and fetch that image and         nobody will be the wiser!</FONT></P>                  <H3><FONT FACE="Helvetica"><A NAME=rawHTML></A>Serving Raw         HTML code</FONT></H3>                  <P><FONT FACE="Helvetica">Since version 1.2 of Notepad         Server you've had the ability to serve straight HTML code         from your Web directory, allowing you immense flexibility in         how you present your information to the world. Couple your         server, your creativity, and </FONT><A HREF="http://www.tow.com/"><FONT FACE="Helvetica">Foundation         Systems'</FONT></A><FONT FACE="Helvetica"> nHTML and you         have an un-beatable creation and service platform right in         the palm of your hand.</FONT></P>                  <BLOCKQUOTE><H3><FONT FACE="Helvetica">So, How does it            work?</FONT></H3>                        <P><FONT FACE="Helvetica">It's blazingly simple to serve            straight HTML. All you have to do is write the code in a            note, being sure to follow the HTML spec by enclosing the            whole document between </FONT><FONT FACE="Helvetica" COLOR="#330099">&lt;HTML&gt;</FONT><FONT FACE="Helvetica">            and </FONT><FONT FACE="Helvetica" COLOR="#330099">&lt;/HTML&gt;</FONT><FONT FACE="Helvetica">            tags. Notepad Server recognizes the </FONT><FONT FACE="Helvetica" COLOR="#330099">&lt;HTML&gt;</FONT><FONT FACE="Helvetica">            tag and serves the exact text of the page rather than            doing any dynamic formatting of it.</FONT></P>                        <H3><FONT FACE="Helvetica">Your Note Should Look Like            This:</FONT></H3>                        <BLOCKQUOTE><FONT FACE="Helvetica" COLOR="#330099"><B><TT>&lt;HTML&gt;</TT></B><TT><BR>               &lt;HEAD&gt;&lt;TITLE&gt;</TT></FONT><FONT FACE="Helvetica" COLOR="#000000"><TT>A               Title</TT></FONT><FONT FACE="Helvetica" COLOR="#330099"><TT>&lt;/TITLE&gt;&lt;/HEAD&gt;<BR>               &lt;BODY&gt;<BR>               </TT></FONT><FONT FACE="Helvetica" COLOR="#000000"><TT>Insert               Body Here</TT></FONT><FONT FACE="Helvetica" COLOR="#330099"><TT><BR>               &lt;/BODY&gt;<BR>               </TT><B><TT>&lt;/HTML&gt;</TT></B></FONT></BLOCKQUOTE></BLOCKQUOTE>                  <H3><FONT FACE="Helvetica">Server Side Includes</FONT></H3>                  <P><FONT FACE="Helvetica">Also supported by Personal Data         Sharing is a series of variables that you can access from         either your text notes or, even better, your raw HTML         documents. On other platforms, these are called <B>Server         Side Includes</B>, so that's what we'll call them         here.</FONT></P>                  <P><FONT FACE="Helvetica">A Table of all SSI supported in         Version 1.5 of Personal Data Sharing is </FONT><A HREF="supported_ssi.html"><FONT FACE="Helvetica">available         here.</FONT></A></P>                  <H4><FONT FACE="Helvetica">How do I USE These         Things?</FONT></H4>                  <P><FONT FACE="Helvetica">Simple. Say you want to include         the access counter in a sentence. You'd write something like         this in your Notepad:</FONT></P>                  <BLOCKQUOTE><FONT FACE="Helvetica"><TT>So far,            </TT></FONT><FONT FACE="Helvetica" COLOR="#330099"><TT>&lt;COUNTER&gt;</TT></FONT><FONT FACE="Helvetica"><TT>            chunks o' knowledge have been spewed into the ether by            this server.</TT></FONT></BLOCKQUOTE>                  <P><FONT FACE="Helvetica">And you'd get:</FONT></P>                  <BLOCKQUOTE><FONT FACE="Helvetica"><TT>So far, 296 chunks o'            knowledge have been spewed into the ether by this            server.</TT></FONT></BLOCKQUOTE>                  <P><FONT FACE="Helvetica">Or, say you always want the title         of your HTML document to reflect the name it has in the         title bar of its Notepad entry. In you header, you'd         write:</FONT></P>                  <BLOCKQUOTE><FONT FACE="Helvetica" COLOR="#330099"><TT>&lt;HTML&gt;&lt;HEAD&gt;&lt;TITLE&gt;&lt;NOTE_TITLE&gt;&lt;/TITLE&gt;&lt;/HEAD&gt;</TT></FONT></BLOCKQUOTE>                  <P><FONT FACE="Helvetica">And even if you changed the name         of the note to Zaphod_Beeblebrox, the title returned by your         HTML will reflect that.</FONT></P>                  <P><FONT FACE="Helvetica">Nifty, huh?</FONT></P>                  <H2><FONT FACE="Helvetica">Special Characters:</FONT></H2>                  <P><FONT FACE="Helvetica">Unless you're lucky enough to use         only the 0-127 ASCII code in your alphabet, you need to be         able to display "International Characters" (such as:         <B>&uuml;, &oslash;, &aring;, &szlig;</B>)</FONT></P>                  <P><FONT FACE="Helvetica">One solution to this is to go         through your notes and subsitute in the &amp;#000 HTML code         for each character and we tried to have PDS do that that but         it's VERY annoying. (Slow, inaccurate, and generally         stupid.)</FONT></P>                  <P><FONT FACE="Helvetica">So, we developed a compromise:         Unlike 90% of the world's HTTP servers, we have chosen to         follow the RFC 2068 standard for HTTP 1.1 Servers and         provide a way for the browsers to interpret these characters         AS TYPED by setting what's called the <B>charset</B> token         in the server's message headers. We also include the same         data in a <TT>&lt;META&gt;</TT> tag in the HEADER of any         generated HTML pages. This helps the browser decide what         encoding to use when viewing your page.</FONT></P>                  <CENTER><FONT FACE="Helvetica"><TABLE BORDER=0 BGCOLOR="#FFFFFF" CELLPADDING=4 WIDTH="60%">            <TR>               <TD>                  <P><FONT FACE="Helvetica">Here's a Sample Header                  From nHTTPd to Illustrate:</FONT></P>                                    <P><FONT FACE="Helvetica">HTTP/1.0 200 OK<BR>                  Server: nHTTPd/1.5<BR>                  Content-type: text/html; </FONT><FONT FACE="Helvetica" COLOR="#CC0000">charset=ISO-8859-1</FONT><FONT FACE="Helvetica"><BR>                  Content-length: 1024</FONT></P>               </TD>            </TR>         </TABLE>          </FONT></CENTER>                  <P><FONT FACE="Helvetica"><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=4>            <TR>               <TD VALIGN=top ROWSPAN=2>                  <P><FONT FACE="Helvetica">In nHTTPd Setup, you can                  select from any of these MIME charsets or None to                  turn off this option entirely.<BR>                  Depending on demand, I may add other                  encodings.</FONT></P>               </TD>               <TD BGCOLOR="#62D6AC">                  <CENTER><FONT FACE="Helvetica"><B>charset                  Selections:</B></FONT></CENTER>               </TD>            </TR>            <TR><TD BGCOLOR="#62D6AC">                  <CENTER><FONT SIZE="-1" FACE="Helvetica"><B>ISO-8859-1</B>:                  The WWW Standard<BR>                  <B>ISO-88259-2</B>: Better for European                  Characters<BR>                  <B>X-MAC-ROMAN</B>: The Standard MacOS Set<BR>                  <B>US-ASCII</B>: The 0-127 Character Set<BR>                  <B>None: </B>No charset token is                  presented</FONT></CENTER>               </TD>            </TR>         </TABLE>          </FONT></P>                  <P><FONT FACE="Helvetica">When I first introduced this         feature with Notepad Server 1.2, I suggested that you add by         hand into your raw HTML the <TT>&lt;META&gt;</TT> tag         containing the charset token. That is no longer required as         this data is provided in the server's message         header.</FONT></P>      </TD>   </TR></TABLE> </FONT><P><FONT FACE="Helvetica">| </FONT><A HREF="start.html"><FONT FACE="Helvetica">Start</FONT></A><FONT FACE="Helvetica">| </FONT><A HREF="serve1.html"><FONT FACE="Helvetica">Serving YourPages</FONT></A><FONT FACE="Helvetica"> |</FONT></P></CENTER></BODY></HTML>