about summary refs log tree commit diff stats
path: root/WWW
diff options
context:
space:
mode:
authorThomas E. Dickey <dickey@invisible-island.net>1997-10-27 19:05:04 -0500
committerThomas E. Dickey <dickey@invisible-island.net>1997-10-27 19:05:04 -0500
commit8f8c57cc7c0e876cd291e2b4de23a52e060b30ba (patch)
treeb813d59380c9db4f7b59bf8a5a965aa606627183 /WWW
parentcbcc3a1e1a82b01eea370bf7841e6b5f4d1e46c1 (diff)
downloadlynx-snapshots-8f8c57cc7c0e876cd291e2b4de23a52e060b30ba.tar.gz
snapshot of project "lynx", label v2-7-1ac_0-89
Diffstat (limited to 'WWW')
-rw-r--r--WWW/Library/Implementation/HTAccess.c76
-rw-r--r--WWW/Library/Implementation/HTAnchor.c22
-rw-r--r--WWW/Library/Implementation/HTAnchor.h4
-rw-r--r--WWW/Library/Implementation/HTGopher.c1
-rw-r--r--WWW/Library/Implementation/HTMLDTD.c194
-rw-r--r--WWW/Library/Implementation/HTString.c132
-rw-r--r--WWW/Library/Implementation/HTString.h3
-rw-r--r--WWW/Library/Implementation/Makefile.old489
-rw-r--r--WWW/Library/Implementation/SGML.c2
-rw-r--r--WWW/Library/Implementation/SGML.h7
-rw-r--r--WWW/Library/Implementation/UCAux.h7
-rw-r--r--WWW/Library/djgpp/CommonMakefile12
-rw-r--r--WWW/Library/djgpp/makefile3
-rw-r--r--WWW/Library/unix/Makefile.old30
14 files changed, 910 insertions, 72 deletions
diff --git a/WWW/Library/Implementation/HTAccess.c b/WWW/Library/Implementation/HTAccess.c
index 2f21eaad..6dedbeb9 100644
--- a/WWW/Library/Implementation/HTAccess.c
+++ b/WWW/Library/Implementation/HTAccess.c
@@ -62,7 +62,6 @@
 #include "HTAlert.h"
 #include "HTCJK.h"
 #include "UCMap.h"
-#include "LYGlobalDefs.h"
 
 #include "LYexit.h"
 #include "LYLeaks.h"
@@ -539,6 +538,8 @@ PRIVATE int get_physical ARGS2(
  *  has finished. - kw @@@   
  */
 
+extern char*UCAssume_MIMEcharset;
+
 PUBLIC void LYUCPushAssumed ARGS1(
     HTParentAnchor *,	anchor)
 {
@@ -550,11 +551,11 @@ PUBLIC void LYUCPushAssumed ARGS1(
 	    anchor_UCI = HTAnchor_getUCInfoStage(anchor,
 						 UCT_STAGE_PARSER);
 	if (anchor_UCI && anchor_UCI->MIMEname) {
-	    pushed_assume_LYhndl = anchor_LYhndl;
-	    UCLYhndl_for_unspec = anchor_LYhndl;
 	    pushed_assume_MIMEname = UCAssume_MIMEcharset;
 	    UCAssume_MIMEcharset = NULL;
 	    StrAllocCopy(UCAssume_MIMEcharset, anchor_UCI->MIMEname);
+	    pushed_assume_LYhndl = anchor_LYhndl;
+	    UCLYhndl_for_unspec = anchor_LYhndl;
 	    return;
 	}
     }
@@ -748,23 +749,60 @@ PRIVATE BOOL HTLoadDocument ARGS4(
     */
     if (!LYforce_no_cache && (text = (HText *)HTAnchor_document(anchor))) {	
 	/*
-	**  Already loaded.  Check it it's OK to use it. - FM
+	**  We have a cached rendition of the target document.
+	**  Check if it's OK to re-use it.  We consider it OK if:
+	**   (1) the anchor does not have the no_cache element set, or
+	**   (2) we've overridden it, e.g., because we are acting on
+	**       a PREV_DOC command or a link in the History Page and
+	**       it's not a reply from a POST with the LYresubmit_posts
+	**       flag set, or
+	**   (3) we are repositioning within the currently loaded document
+	**       based on the target anchor's address (URL_Reference).
+	*
+	*    If DONT_TRACK_INTERNAL_LINKS is defined, HText_AreDifferent()
+	*    is used to determine whether (3) applies.  If the target address
+	*    differs from that of the current document only by a fragment
+	*    and the taget address has an appended fragment, repositioning
+	*    without reloading is always assumed.
+	*    Note that HText_AreDifferent() currently always returns TRUE
+	*    if the target has a LYNXIMGMAP URL, so that an internally
+	*    generated pseudo-document will normally not be re-used unless
+	*    condition (2) appplies. (Condition (1) cannot apply since in
+	*    LYMap.c, no_cache is always set in the anchor object).  This
+	*    doesn't guarantee that the resource from which the MAP element
+	*    is taken will be read again (reloaded) when the list of links
+	*    for a client-side image map is regenerated, when in some cases
+	*    it should (e.g. user requested RELOAD, or HTTP response with
+	*    no-cache header and we are not overriding).
+	*
+	*    If DONT_TRACK_INTERNAL_LINKS is undefined, a target address that
+	*    points to the same URL as the current document may still result in
+	*    reloading, depending on whether the original URL-Reference
+	*    was given as an internal link in the context of the previously
+	*    loaded document.  HText_AreDifferent() is not used here for
+	*    testing whether we are just repositioning.  For an internal
+	*    link, the potential callers of this function from mainloop()
+	*    down will either avoid making the call (and do the repositioning
+	*    differently) or set LYoverride_no_cache.
+	*    Note that (a) LYNXIMGMAP pseudo-documents and (b) The "List Page"
+	*    document are treated logically as being part of the document on
+	*    which they are based, for the purpose of whether to treat a link
+	*    as internal, but the logic for this (by setting LYoverride_no_cache
+	*    as necessary) is implemented elsewhere.  For LYNXIMGMAP the same
+	*    caveat as above applies.
+	*
+	**  We also should be checking other aspects of cache
+	**  regulation (e.g., based on an If-Modified-Since check,
+	**  etc.) but the code for doing those other things isn't
+	**  available yet.
 	*/
-#ifdef NOTUSED_FOTEMODS
-	/* not sure whether this is always the right thing to do,
-	 * and anyway, we have a far more complete (and complicated...)
-	 * way to prevent reloading on internal URL references now...
-	 * - kw
-	 */
-	if ((cp = strchr(address_to_load, '#')) != NULL) {
-	    *cp = '\0';
-	    if (!strcmp(address_to_load, HTLoadedDocumentURL()) &&
-	        strncasecomp(address_to_load, "LYNXIMGMAP:", 11))
-	        LYoverride_no_cache = TRUE;
-	    *cp = '#';
-	}
-#endif /* NOTUSED_FOTEMODS */
-	if (LYoverride_no_cache || !HText_hasNoCacheSet(text)) {
+#ifdef DONT_TRACK_INTERNAL_LINKS
+	if (LYoverride_no_cache || !HText_hasNoCacheSet(text) ||
+	    !HText_AreDifferent(anchor, full_address))
+#else
+	if (LYoverride_no_cache || !HText_hasNoCacheSet(text))
+#endif /* TRACK_INTERNAL_LINKS */
+	{
             if (TRACE)
 	        fprintf(stderr, "HTAccess: Document already in memory.\n");
             HText_select(text);
diff --git a/WWW/Library/Implementation/HTAnchor.c b/WWW/Library/Implementation/HTAnchor.c
index 6db5f974..d3c3f34e 100644
--- a/WWW/Library/Implementation/HTAnchor.c
+++ b/WWW/Library/Implementation/HTAnchor.c
@@ -20,18 +20,14 @@
 #include <ctype.h>
 #include "HTAnchor.h"
 #include "HTParse.h"
-#ifdef EXP_CHARTRANS
 #include "UCAux.h"
 #include "UCMap.h"
-#endif /* EXP_CHARTRANS */
 
 #include "LYLeaks.h"
 
 #define FREE(x) if (x) {free(x); x = NULL;}
 
-#ifdef EXP_CHARTRANS
 extern LYUCcharset LYCharSet_UC[];
-#endif
 
 #ifdef NOT_DEFINED
 /*
@@ -501,10 +497,11 @@ PRIVATE void deleteLinks ARGS1(
 	        me->parent != parent) {
 	        HTAnchor_delete(parent);
 	    }
-	    /* The link structure has to be deleted, too!
-	    ** That was missing, but this code probably never
-	    ** got exercised by Lynx.  - kw
-	    */
+	    /*
+	     *  The link structure has to be deleted, too!
+	     *  That was missing, but this code probably never
+	     *  got exercised by Lynx.  - KW
+	     */
 	    FREE(target);
         }
 
@@ -663,7 +660,7 @@ PUBLIC BOOL HTAnchor_delete ARGS1(
     FREE(me->expires);
     FREE(me->last_modified);
     FREE(me->server);
-#ifdef USEHASH
+#ifdef USE_HASH
     FREE(me->style);
 #endif
  
@@ -829,7 +826,7 @@ PUBLIC BOOL HTAnchor_hasChildren ARGS1(
     return me ? ! HTList_isEmpty(me->children) : NO;
 }
 
-#if defined(USEHASH)
+#if defined(USE_HASH)
 /*      Style handling.
 */
 PUBLIC CONST char * HTAnchor_style ARGS1(
@@ -1159,8 +1156,6 @@ PUBLIC void HTAnchor_setPhysical ARGS2(
     }
 }
 
-#ifdef EXP_CHARTRANS
-
 /*
 **  We store charset info in the HTParentAnchor object, for several
 **  "stages".  (See UCDefs.h)
@@ -1312,13 +1307,10 @@ PUBLIC LYUCcharset * HTAnchor_copyUCInfoStage ARGS4(
 	    me->UCStages->s[to_stage].lock = set_by;
 	    me->UCStages->s[to_stage].LYhndl =
 		me->UCStages->s[from_stage].LYhndl;
-
 	    if (p_to != p_from)
 		memcpy(p_to, p_from, sizeof(LYUCcharset));
-
 	    return p_to;
 	}
     }
     return NULL;
 }
-#endif /* EXP_CHARTRANS */
diff --git a/WWW/Library/Implementation/HTAnchor.h b/WWW/Library/Implementation/HTAnchor.h
index 8818b36d..458cac40 100644
--- a/WWW/Library/Implementation/HTAnchor.h
+++ b/WWW/Library/Implementation/HTAnchor.h
@@ -98,7 +98,7 @@ struct _HTParentAnchor {
   char *        title;          /* Title of document */
   char *        owner;          /* Owner of document */
   char *        RevTitle;       /* TITLE in REV="made" or REV="owner" LINK */
-#ifdef USEHASH
+#ifdef USE_HASH
   char *	style;
 #endif
 
@@ -263,7 +263,7 @@ extern BOOL HTAnchor_isISMAPScript PARAMS((
 extern BOOL HTAnchor_hasChildren PARAMS((
 	HTParentAnchor *	me));
 
-#if defined(USEHASH)
+#if defined(USE_HASH)
 extern CONST char * HTAnchor_style PARAMS((
 	HTParentAnchor *	me));
 
diff --git a/WWW/Library/Implementation/HTGopher.c b/WWW/Library/Implementation/HTGopher.c
index c94c89d8..d4e1673e 100644
--- a/WWW/Library/Implementation/HTGopher.c
+++ b/WWW/Library/Implementation/HTGopher.c
@@ -1583,6 +1583,7 @@ PUBLIC int HTLoadCSO ARGS4(
 	    }
 	}
     }
+    anAnchor->safe = TRUE;
     if (!(anAnchor->post_data && *anAnchor->post_data)) {
         generate_cso_form(host, port, buf, Target);
 	(*Target->isa->_free)(Target);
diff --git a/WWW/Library/Implementation/HTMLDTD.c b/WWW/Library/Implementation/HTMLDTD.c
index cef1eaef..a519fb82 100644
--- a/WWW/Library/Implementation/HTMLDTD.c
+++ b/WWW/Library/Implementation/HTMLDTD.c
@@ -161,133 +161,285 @@ static CONST char* entities[] = {
 static CONST UC_entity_info extra_entities[] = {
   {"Aacute",	0x00c1},  /* A with acute */
   {"Abreve",	0x0102},  /* A with breve */
-  {"Acirc",	0x00c2},  /* A with circumflex */
+  {"Acirc",	0x00c2},  /* capital A, circumflex accent */
+  {"Alpha",	0x0391},  /* greek capital letter alpha,  u+0391 */
   {"Aogon",	0x0104},  /* A with ogonek */
-  {"Auml",	0x00c4},  /* A with diaeresis */
+  {"Auml",	0x00c4},  /* capital A, dieresis or umlaut mark */
+  {"Beta",	0x0392},  /* greek capital letter beta,  u+0392 */
   {"Cacute",	0x0106},  /* C with acute */
   {"Ccaron",	0x010c},  /* C with caron */
-  {"Ccedil",	0x00c7},  /* C with cedilla */
+  {"Ccedil",	0x00c7},  /* capital C, cedilla */
+  {"Chi",	0x03a7},  /* greek capital letter chi,  u+03A7 */
+  {"Dagger",	0x2021},  /* double dagger, u+2021 ISOpub */
   {"Dcaron",	0x010e},  /* D with caron */
+  {"Delta",	0x0394},  /* greek capital letter delta,  u+0394 ISOgrk3 */
   {"Dstrok",	0x0110},  /* D with stroke */
   {"Eacute",	0x00c9},  /* E with acute */
   {"Ecaron",	0x011a},  /* E with caron */
   {"Eogon",	0x0118},  /* E with ogonek */
-  {"Euml",	0x00cb},  /* E with diaeresis */
+  {"Epsilon",	0x0395},  /* greek capital letter epsilon,  u+0395 */
+  {"Eta",	0x0397},  /* greek capital letter eta,  u+0397 */
+  {"Euml",	0x00cb},  /* capital E, dieresis or umlaut mark */
+  {"Gamma",	0x0393},  /* greek capital letter gamma,  u+0393 ISOgrk3 */
   {"Iacute",	0x00cd},  /* I with acute */
-  {"Icirc",	0x00ce},  /* I with circumflex */
+  {"Icirc",	0x00ce},  /* capital I, circumflex accent */
+  {"Iota",	0x0399},  /* greek capital letter iota,  u+0399 */
+  {"Kappa",	0x039a},  /* greek capital letter kappa,  u+039A */
   {"Lacute",	0x0139},  /* L with acute */
+  {"Lambda",	0x039b},  /* greek capital letter lambda,  u+039B ISOgrk */
   {"Lcaron",	0x013d},  /* L with caron */
   {"Lstrok",	0x0141},  /* L with stroke */
+  {"Mu",	0x039c},  /* greek capital letter mu,  u+039C */
   {"Nacute",	0x0143},  /* N with acute */
   {"Ncaron",	0x0147},  /* N with caron */
+  {"Ntilde",	0x00d1},  /* capital N, tilde */
+  {"Nu",	0x039d},  /* greek capital letter nu,  u+039D */
+  {"OElig",	0x0152},  /* latin capital ligature oe, u+0152 ISOlat2 - */
   {"Oacute",	0x00d3},  /* O with acute */
   {"Ocirc",	0x00d4},  /* O with circumflex */
   {"Odblac",	0x0150},  /* O with double acute */
+  {"Ograve",	0x00d2},  /* capital O, grave accent */
+  {"Omega",	0x03a9},  /* greek capital letter omega,  u+03A9 ISOgrk3 */
+  {"Omicron",	0x039f},  /* greek capital letter omicron,  u+039F */
   {"Ouml",	0x00d6},  /* O with diaeresis */
+  {"Phi",	0x03a6},  /* greek capital letter phi,  u+03A6 ISOgrk3 - */
+  {"Pi",	0x03a0},  /* greek capital letter pi,  u+03A0 ISOgrk3 -- */
+  {"Prime",	0x2033},  /* double prime, =seconds, =inches, u+2033 IS */
+  {"Psi",	0x03a8},  /* greek capital letter psi,  u+03A8 ISOgrk3 - */
   {"Racute",	0x0154},  /* R with acute */
   {"Rcaron",	0x0158},  /* R with caron */
+  {"Rho",	0x03a1},  /* greek capital letter rho,  u+03A1 */
   {"Sacute",	0x015a},  /* S with acute */
   {"Scaron",	0x0160},  /* S with caron */
   {"Scedil",	0x015e},  /* S with cedilla */
+  {"Sigma",	0x03a3},  /* greek capital letter sigma,  u+03A3 ISOgrk3 */
+  {"Tau",	0x03a4},  /* greek capital letter tau,  u+03A4 */
   {"Tcaron",	0x0164},  /* T with caron */
   {"Tcedil",	0x0162},  /* T with cedilla */
+  {"Theta",	0x0398},  /* greek capital letter theta,  u+0398 ISOgrk3 */
   {"Uacute",	0x00da},  /* U with acute */
   {"Udblac",	0x0170},  /* U with double acute */
+  {"Ugrave",	0x00d9},  /* capital U, grave accent */
+  {"Upsilon",	0x03a5},  /* greek capital letter upsilon,  u+03A5 IS */
   {"Uring",	0x016e},  /* U with ring above */
-  {"Uuml",	0x00dc},  /* U with diaeresis */
-  {"Yacute",	0x00dd},  /* Y with acute */
+  {"Uuml",	0x00dc},  /* capital U, dieresis or umlaut mark */
+  {"Xi",	0x039e},  /* greek capital letter xi,  u+039E ISOgrk3 -- */
+  {"Yacute",	0x00dd},  /* capital Y, acute accent */
+  {"Yuml",	0x0178},  /* latin capital letter y with diaeresis, u+01 */
   {"Zacute",	0x0179},  /* Z with acute */
   {"Zcaron",	0x017d},  /* Z with caron */
   {"Zdot",	0x017b},  /* Z with dot above */
+  {"Zeta",	0x0396},  /* greek capital letter zeta,  u+0396 */
   {"aacute",	0x00e1},  /* a with acute */
   {"abreve",	0x0103},  /* a with breve */
   {"acirc",	0x00e2},  /* a with circumflex */
   {"acute",	0x00b4},  /* acuteaccent */
-  {"amp",	0x0026},  /* ampersand */
+  {"alefsym",	0x2135},  /* alef symbol, =first transfinite cardinal, */
+  {"alpha",	0x03b1},  /* greek small letter alpha, u+03B1 ISOgrk3 -- */
+  {"amp",	0x0026},  /* ampersand, u+0026 ISOnum */
+  {"and",	0x2227},  /* logical and, =wedge, u+2227 ISOtech */
+  {"ang",	0x2220},  /* angle, u+2220 ISOamso */
   {"aogon",	0x0105},  /* a with ogonek */
   {"apos",	0x0027},  /* apostrophe */
   {"ast",	0x002a},  /* asterisk */
-  {"auml",	0x00e4},  /* a with diaeresis */
+  {"asymp",	0x2248},  /* almost equal to, =asymptotic to, u+2248 IS */
+  {"auml",	0x00e4},  /* small a, dieresis or umlaut mark */
+  {"bdquo",	0x201e},  /* double low-9 quotation mark, u+201E NEW -- */
+  {"beta",	0x03b2},  /* greek small letter beta,  u+03B2 ISOgrk3 -- */
   {"breve",	0x02d8},  /* breve */
   {"bsol",	0x005c},  /* reversesolidus */
+  {"bull",	0x2022},  /* bullet, =black small circle, u+2022 ISOpub */
   {"cacute",	0x0107},  /* c with acute */
+  {"cap",	0x2229},  /* intersection, =cap, u+2229 ISOtech */
   {"caron",	0x02c7},  /* caron */
   {"ccaron",	0x010d},  /* c with caron */
   {"ccedil",	0x00e7},  /* c with cedilla */
   {"cedil",	0x00b8},  /* cedilla */
-  {"circ",	0x005e},  /* circumflexaccent */
+  {"cent",	0x00a2},  /* cent sign */
+  {"chi",	0x03c7},  /* greek small letter chi,  u+03C7 ISOgrk3 */
+  {"circ",	0x02c6},  /* modifier letter circumflex accent, u+02C6 */
+  {"clubs",	0x2663},  /* black club suit, =shamrock, u+2663 ISOpub */
   {"colon",	0x003a},  /* colon */
   {"comma",	0x002c},  /* comma */
   {"commat",	0x0040},  /* commercialat */
-  {"curren",	0x00a4},  /* currencysign */
+  {"cong",	0x2245},  /* approximately equal to, u+2245 ISOtech */
+  {"crarr",	0x21b5},  /* downwards arrow with corner leftwards, =ca */
+  {"cup",	0x222a},  /* union, =cup, u+222A ISOtech */
+  {"curren",	0x00a4},  /* general currency sign */
+  {"dArr",	0x21d3},  /* downwards double arrow, u+21D3 ISOamsa */
+  {"dagger",	0x2020},  /* dagger, u+2020 ISOpub */
+  {"darr",	0x2193},  /* downwards arrow, u+2193 ISOnum */
   {"dblac",	0x02dd},  /* doubleacuteaccent */
   {"dcaron",	0x010f},  /* d with caron */
   {"deg",	0x00b0},  /* degreesign */
+  {"delta",	0x03b4},  /* greek small letter delta,  u+03B4 ISOgrk3 - */
+  {"diams",	0x2666},  /* black diamond suit, u+2666 ISOpub */
   {"divide",	0x00f7},  /* divisionsign */
   {"dollar",	0x0024},  /* dollarsign */
   {"dot",	0x02d9},  /* dotabove */
   {"dstrok",	0x0111},  /* d with stroke */
   {"eacute",	0x00e9},  /* e with acute */
   {"ecaron",	0x011b},  /* e with caron */
+  {"ecirc",	0x00ea},  /* small e, circumflex accent */
+  {"empty",	0x2205},  /* empty set, =null set, =diameter, u+2205 IS */
+  {"emsp",	0x2003},  /* em space, u+2003 ISOpub */
+  {"ensp",	0x2002},  /* en space, u+2002 ISOpub */
   {"eogon",	0x0119},  /* e with ogonek */
+  {"epsilon",	0x03b5},  /* greek small letter epsilon,  u+03B5 ISOg */
   {"equals",	0x003d},  /* equalssign */
+  {"equiv",	0x2261},  /* identical to, u+2261 ISOtech */
+  {"eta",	0x03b7},  /* greek small letter eta,  u+03B7 ISOgrk3 */
   {"euml",	0x00eb},  /* e with diaeresis */
   {"excl",	0x0021},  /* exclamationmark */
+  {"exist",	0x2203},  /* there exists, u+2203 ISOtech */
+  {"fnof",	0x0192},  /* latin small f with hook, =function, =flori */
+  {"forall",	0x2200},  /* for all, u+2200 ISOtech */
+  {"frasl",	0x2044},  /* fraction slash, u+2044 NEW */
+  {"gamma",	0x03b3},  /* greek small letter gamma,  u+03B3 ISOgrk3 - */
+  {"ge",	0x2265},  /* greater-than or equal to, u+2265 ISOtech - */
   {"grave",	0x0060},  /* graveaccent */
   {"gt",	0x003e},  /* greater-thansign */
+  {"hArr",	0x21d4},  /* left right double arrow, u+21D4 ISOamsa -- */
+  {"harr",	0x2194},  /* left right arrow, u+2194 ISOamsa */
+  {"hearts",	0x2665},  /* black heart suit, =valentine, u+2665 ISOpu */
+  {"hellip",	0x2026},  /* horizontal ellipsis, =three dot leader, u+ */
   {"hyphen",	0x002d},  /* hyphen-minus */
   {"iacute",	0x00ed},  /* i with acute */
-  {"icirc",	0x00ee},  /* i with circumflex */
+  {"icirc",	0x00ee},  /* small i, circumflex accent */
+  {"image",	0x2111},  /* blackletter capital I, =imaginary part, u+ */
+  {"infin",	0x221e},  /* infinity, u+221E ISOtech */
+  {"int",	0x222b},  /* integral, u+222B ISOtech */
+  {"iota",	0x03b9},  /* greek small letter iota,  u+03B9 ISOgrk3 -- */
+  {"isin",	0x2208},  /* element of, u+2208 ISOtech */
+  {"kappa",	0x03ba},  /* greek small letter kappa,  u+03BA ISOgrk3 - */
+  {"lArr",	0x21d0},  /* leftwards double arrow, u+21D0 ISOtech */
   {"lacute",	0x013a},  /* l with acute */
+  {"lambda",	0x03bb},  /* greek small letter lambda,  u+03BB ISOgrk3 */
+  {"lang",	0x2329},  /* left-pointing angle bracket, =bra, u+2329 */
+  {"larr",	0x2190},  /* leftwards arrow, u+2190 ISOnum */
   {"lcaron",	0x013e},  /* l with caron */
+  {"lceil",	0x2308},  /* left ceiling, =apl upstile, u+2308, ISOams */
   {"lcub",	0x007b},  /* leftcurlybracket */
+  {"ldquo",	0x201c},  /* left double quotation mark, u+201C ISOnum */
+  {"le",	0x2264},  /* less-than or equal to, u+2264 ISOtech */
+  {"lfloor",	0x230a},  /* left floor, =apl downstile, u+230A, ISOams */
+  {"lowast",	0x2217},  /* asterisk operator, u+2217 ISOtech */
   {"lowbar",	0x005f},  /* lowline */
+  {"loz",	0x25ca},  /* lozenge, u+25CA ISOpub */
   {"lpar",	0x0028},  /* leftparenthesis */
-  {"lrm",	 8206},	/* left-to-right mark */ 
+  {"lrm",	0x200e},  /* left-to-right mark, u+200E NEW RFC 2070 -- */
+  {"lsaquo",	0x2039},  /* single left-pointing angle quotation mark, */
   {"lsqb",	0x005b},  /* leftsquarebracket */
+  {"lsquo",	0x2018},  /* left single quotation mark, u+2018 ISOnum */
   {"lstrok",	0x0142},  /* l with stroke */
   {"lt",	0x003c},  /* less-thansign */
+  {"macr",	0x00af},  /* macron */
+  {"mdash",	0x2014},  /* em dash, u+2014 ISOpub */
+  {"minus",	0x2212},  /* minus sign, u+2212 ISOtech */
+  {"mu",	0x03bc},  /* greek small letter mu,  u+03BC ISOgrk3 */
+  {"nabla",	0x2207},  /* nabla, =backward difference, u+2207 ISOtec */
   {"nacute",	0x0144},  /* n with acute */
-  {"nbsp",	0x00a0},  /* no-breakspace */
+  {"nbsp",	0x00a0},  /* no-break space */
   {"ncaron",	0x0148},  /* n with caron */
+  {"ndash",	0x2013},  /* en dash, u+2013 ISOpub */
+  {"ne",	0x2260},  /* not equal to, u+2260 ISOtech */
+  {"ni",	0x220b},  /* contains as member, u+220B ISOtech */
+  {"notin",	0x2209},  /* not an element of, u+2209 ISOtech */
+  {"nsub",	0x2284},  /* not a subset of, u+2284 ISOamsn */
+  {"nu",	0x03bd},  /* greek small letter nu,  u+03BD ISOgrk3 */
   {"num",	0x0023},  /* numbersign */
   {"oacute",	0x00f3},  /* o with acute */
   {"ocirc",	0x00f4},  /* o with circumflex */
   {"odblac",	0x0151},  /* o with double acute */
+  {"oelig",	0x0153},  /* latin small ligature oe, u+0153 ISOlat2 */
   {"ogon",	0x02db},  /* ogonek */
-  {"ouml",	0x00f6},  /* o with diaeresis */
+  {"ograve",	0x00f2},  /* small o, grave accent */
+  {"oline",	0x203e},  /* overline, =spacing overscore, u+203E NEW - */
+  {"omega",	0x03c9},  /* greek small letter omega,  u+03C9 ISOgrk3 - */
+  {"omicron",	0x03bf},  /* greek small letter omicron,  u+03BF NEW */
+  {"oplus",	0x2295},  /* circled plus, =direct sum, u+2295 ISOamsb */
+  {"or",	0x2228},  /* logical or, =vee, u+2228 ISOtech */
+  {"oslash",	0x00f8},  /* small o, slash */
+  {"otimes",	0x2297},  /* circled times, =vector product, u+2297 ISO */
+  {"ouml",	0x00f6},  /* small o, dieresis or umlaut mark */
+  {"part",	0x2202},  /* partial differential, u+2202 ISOtech  */
   {"percnt",	0x0025},  /* percentsign */
   {"period",	0x002e},  /* fullstop */
+  {"permil",	0x2030},  /* per mille sign, u+2030 ISOtech */
+  {"perp",	0x22a5},  /* up tack, =orthogonal to, =perpendicular, u */
+  {"phi",	0x03c6},  /* greek small letter phi,  u+03C6 ISOgrk3 */
+  {"pi",	0x03c0},  /* greek small letter pi,  u+03C0 ISOgrk3 */
+  {"piv",	0x03d6},  /* greek pi symbol,  u+03D6 ISOgrk3 */
   {"plus",	0x002b},  /* plussign */
+  {"plusmn",	0x00b1},  /* plus-or-minus sign */
+  {"prime",	0x2032},  /* prime, =minutes, =feet, u+2032 ISOtech */
+  {"prod",	0x220f},  /* n-ary product, =product sign, u+220F ISOam */
+  {"prop",	0x221d},  /* proportional to, u+221D ISOtech */
+  {"psi",	0x03c8},  /* greek small letter psi,  u+03C8 ISOgrk3 */
   {"quest",	0x003f},  /* questionmark */
   {"quot",	0x0022},  /* quotationmark */
+  {"rArr",	0x21d2},  /* rightwards double arrow, u+21D2 ISOtech -- */
   {"racute",	0x0155},  /* r with acute */
+  {"radic",	0x221a},  /* square root, =radical sign, u+221A ISOtech */
+  {"rang",	0x232a},  /* right-pointing angle bracket, =ket, u+232A */
+  {"rarr",	0x2192},  /* rightwards arrow, u+2192 ISOnum */
   {"rcaron",	0x0159},  /* r with caron */
+  {"rceil",	0x2309},  /* right ceiling, u+2309, ISOamsc  */
   {"rcub",	0x007d},  /* rightcurlybracket */
+  {"rdquo",	0x201d},  /* right double quotation mark, u+201D ISOnum */
+  {"real",	0x211c},  /* blackletter capital R, =real part symbol, */
+  {"rfloor",	0x230b},  /* right floor, u+230B, ISOamsc  */
+  {"rho",	0x03c1},  /* greek small letter rho,  u+03C1 ISOgrk3 */
   {"rlm",	 8207},	/* right-to-left mark */ 
   {"rpar",	0x0029},  /* rightparenthesis */
+  {"rsaquo",	0x203a},  /* single right-pointing angle quotation mark */
   {"rsqb",	0x005d},  /* rightsquarebracket */
+  {"rsquo",	0x2019},  /* right single quotation mark, u+2019 ISOnum */
   {"sacute",	0x015b},  /* s with acute */
-  {"scaron",	0x0161},  /* s with caron */
+  {"sbquo",	0x201a},  /* single low-9 quotation mark, u+201A NEW -- */
+  {"scaron",	0x0161},  /* latin small letter s with caron, u+0161 ISO */
   {"scedil",	0x015f},  /* s with cedilla */
-  {"sect",	0x00a7},  /* sectionsign */
+  {"sdot",	0x22c5},  /* dot operator, u+22C5 ISOamsb */
+  {"sect",	0x00a7},  /* section sign */
   {"semi",	0x003b},  /* semicolon */
-  {"shy",	0x00ad},  /* softhyphen */
+  {"shy",	0x00ad},  /* soft hyphen */
+  {"sigma",	0x03c3},  /* greek small letter sigma,  u+03C3 ISOgrk3 - */
+  {"sigmaf",	0x03c2},  /* greek small letter final sigma,  u+03C2 ISO */
+  {"sim",	0x223c},  /* tilde operator, =varies with, =similar to, */
   {"sol",	0x002f},  /* solidus */
+  {"spades",	0x2660},  /* black spade suit, u+2660 ISOpub */
+  {"sub",	0x2282},  /* subset of, u+2282 ISOtech */
+  {"sube",	0x2286},  /* subset of or equal to, u+2286 ISOtech */
+  {"sum",	0x2211},  /* n-ary sumation, u+2211 ISOamsb */
+  {"sup",	0x2283},  /* superset of, u+2283 ISOtech */
+  {"supe",	0x2287},  /* superset of or equal to, u+2287 ISOtech -- */
+  {"tau",	0x03c4},  /* greek small letter tau,  u+03C4 ISOgrk3 */
   {"tcaron",	0x0165},  /* t with caron */
   {"tcedil",	0x0163},  /* t with cedilla */
-  {"tilde",	0x007e},  /* tilde */
-  {"times",	0x00d7},  /* multiplicationsign */
+  {"there4",	0x2234},  /* therefore, u+2234 ISOtech */
+  {"theta",	0x03b8},  /* greek small letter theta,  u+03B8 ISOgrk3 - */
+  {"thetasym",	0x03d1},  /* greek small letter theta symbol,  u+03D1 */
+  {"thinsp",	0x2009},  /* thin space, u+2009 ISOpub */
+  {"tilde",	0x02dc},  /* small tilde, u+02DC ISOdia */
+  {"times",	0x00d7},  /* multiply sign */
+  {"trade",	0x2122},  /* trade mark sign, u+2122 ISOnum */
+  {"uArr",	0x21d1},  /* upwards double arrow, u+21D1 ISOamsa */
   {"uacute",	0x00fa},  /* u with acute */
+  {"uarr",	0x2191},  /* upwards arrow, u+2191 ISOnum--> */
   {"udblac",	0x0171},  /* u with double acute */
-  {"uml",	0x00a8},  /* diaeresis */
+  {"uml",	0x00a8},  /* umlaut (dieresis) */
+  {"upsih",	0x03d2},  /* greek upsilon with hook symbol,  u+03D2 NEW */
+  {"upsilon",	0x03c5},  /* greek small letter upsilon,  u+03C5 ISOg */
   {"uring",	0x016f},  /* u with ring above */
   {"uuml",	0x00fc},  /* u with diaeresis */
   {"verbar",	0x007c},  /* verticalline */
+  {"weierp",	0x2118},  /* script capital P, =power set, =Weierstrass */
+  {"xi",	0x03be},  /* greek small letter xi,  u+03BE ISOgrk3 */
   {"yacute",	0x00fd},  /* y with acute */
   {"zacute",	0x017a},  /* z with acute */
   {"zcaron",	0x017e},  /* z with caron */
   {"zdot",	0x017c},  /* z with dot above */
+  {"zeta",	0x03b6},  /* greek small letter zeta,  u+03B6 ISOgrk3 -- */
   {"zwj",	 8205},	/* zero width joiner */ 
   {"zwnj",	 8204},	/* zero width non-joiner */ 
 
diff --git a/WWW/Library/Implementation/HTString.c b/WWW/Library/Implementation/HTString.c
index 9f693924..3f3c9f4b 100644
--- a/WWW/Library/Implementation/HTString.c
+++ b/WWW/Library/Implementation/HTString.c
@@ -154,3 +154,135 @@ PUBLIC char * HTNextField ARGS1(
     *pstr = p;
     return start;
 }
+
+/*	Find next Token
+**	---------------
+**	Finds the next token in a string
+**	On entry,
+**	*pstr	points to a string to be parsed.
+**      delims  lists characters to be recognized as delimiters.
+**              If NULL default is white white space "," ";" or "=".
+**              The word can optionally be quoted or enclosed with
+**		chars from bracks.
+**		Comments surrrounded by '(' ')' are filtered out
+**		unless they are specifically reqested by including
+**		' ' or '(' in delims or bracks.
+**      bracks  lists bracketing chars.  Some are recognized as
+**              special, for those give the opening char.
+**		If NULL defaults to <"> and "<" ">".
+**      found   points to location to fill with the ending delimiter
+**              found, or is NULL.
+**
+** 	On exit,
+**	*pstr	has been moved to the first delimiter past the
+**		field
+**		THE STRING HAS BEEN MUTILATED by a 0 terminator
+**      found   points to the delimiter found unless it was NULL.
+**	Returns	a pointer to the first word or NULL on error
+*/
+PUBLIC char * HTNextTok (char ** pstr,
+		      const char * delims, const char * bracks, char * found)
+{
+    char * p = *pstr;
+    char * start = NULL;
+    BOOL get_blanks, skip_comments;
+    BOOL get_comments;
+    BOOL get_closing_char_too = FALSE;
+    char closer;
+    if (!pstr || !*pstr) return NULL;
+    if (!delims) delims = " ;,=" ;
+    if (!bracks) bracks = "<\"" ;
+
+    get_blanks = (!strchr(delims,' ') && !strchr(bracks,' '));
+    get_comments = (strchr(bracks,'(') != NULL);
+    skip_comments = (!get_comments && !strchr(delims,'(') && !get_blanks); 
+#define skipWHITE(c) (!get_blanks && WHITE(c))
+
+    while (*p && skipWHITE(*p))
+        p++;				/* Strip white space */
+    if (!*p) {
+	*pstr = p;
+	if (found) *found = '\0';
+        return NULL;		/* No first field */
+    }
+    while (1) {
+	/* Strip white space and other delimiters */
+	while (*p && (skipWHITE(*p) || strchr(delims,*p))) p++;
+	if (!*p) {
+	    *pstr = p;
+	    if (found) *found = *(p-1);
+	    return NULL;				   	 /* No field */
+	}
+
+	if (*p == '(' && (skip_comments || get_comments)) {	  /* Comment */
+	    int comment_level = 0;
+	    if (get_comments && !start) start = p+1;
+	    for(;*p && (*p!=')' || --comment_level>0); p++) {
+		if (*p == '(') comment_level++;
+		else if (*p == '"') {	      /* quoted field within Comment */
+		    for(p++; *p && *p!='"'; p++)
+			if (*p == '\\' && *(p+1)) p++; /* Skip escaped chars */
+		    if (!*p) break; /* (invalid) end of string found, leave */
+		}
+		if (*p == '\\' && *(p+1)) p++;	       /* Skip escaped chars */
+	    }
+	    if (get_comments)
+		break;
+	    if (*p) p++;
+	    if (get_closing_char_too) {
+		if (!*p || (!strchr(bracks,*p) && strchr(delims,*p))) {
+		    break;
+		} else
+		    get_closing_char_too = (strchr(bracks,*p) != NULL);
+	    }
+	} else if (strchr(bracks,*p)) {	       /* quoted or bracketted field */
+	    switch (*p) {
+	       case '<': closer = '>'; break;
+	       case '[': closer = ']'; break;
+	       case '{': closer = '}'; break;
+	       case ':': closer = ';'; break;
+	    default:     closer = *p;
+	    }
+	    if (!start) start = ++p;
+	    for(;*p && *p!=closer; p++)
+		if (*p == '\\' && *(p+1)) p++;	       /* Skip escaped chars */
+	    if (get_closing_char_too) {
+		p++;
+		if (!*p || (!strchr(bracks,*p) && strchr(delims,*p))) {
+		    break;
+		} else
+		    get_closing_char_too = (strchr(bracks,*p) != NULL);
+	    } else
+	    break;			    /* kr95-10-9: needs to stop here */
+#if 0
+	} else if (*p == '<') {				     /* quoted field */
+	    if (!start) start = ++p;
+	    for(;*p && *p!='>'; p++)
+		if (*p == '\\' && *(p+1)) p++;	       /* Skip escaped chars */
+	    break;			    /* kr95-10-9: needs to stop here */
+#endif
+	} else {					      /* Spool field */
+	    if (!start) start = p;
+	    while(*p && !skipWHITE(*p) && !strchr(bracks,*p) &&
+		                          !strchr(delims,*p))
+		p++;
+	    if (*p && strchr(bracks,*p)) {
+		get_closing_char_too = TRUE;
+	    } else {
+		if (*p=='(' && skip_comments) {
+		    *pstr = p;
+		    HTNextTok(pstr, NULL, "(", found);  /*      Advance pstr */
+		    *p = '\0';
+		    if (*pstr && **pstr) (*pstr)++;
+		    return start;
+		}
+		    break;					   /* Got it */
+	    }
+	}
+    }
+    if (found) *found = *p;
+	
+    if (*p) *p++ = '\0';
+    *pstr = p;
+    return start;
+}
diff --git a/WWW/Library/Implementation/HTString.h b/WWW/Library/Implementation/HTString.h
index 7fad84bb..ffc79e64 100644
--- a/WWW/Library/Implementation/HTString.h
+++ b/WWW/Library/Implementation/HTString.h
@@ -42,6 +42,9 @@ Next word or quoted string
  */
 extern char * HTNextField PARAMS ((char** pstr));
 
+/* A more general parser - kw */
+extern char * HTNextTok (char ** pstr,
+		      const char * delims, const char * bracks, char * found);
 
 #endif
 /*
diff --git a/WWW/Library/Implementation/Makefile.old b/WWW/Library/Implementation/Makefile.old
new file mode 100644
index 00000000..7f028976
--- /dev/null
+++ b/WWW/Library/Implementation/Makefile.old
@@ -0,0 +1,489 @@
+# Makefile generated by imake - do not edit!
+# $XConsortium: imake.c,v 1.51 89/12/12 12:37:30 jim Exp $
+#
+# The cpp used on this machine replaces all newlines and multiple tabs and
+# spaces in a macro expansion with a single space.  Imake tries to compensate
+# for this, but is not always successful.
+#
+
+###########################################################################
+# Makefile generated from "Imake.tmpl" and </tmp/IIf.a00214>
+# $XConsortium: Imake.tmpl,v 1.77 89/12/18 17:01:37 jim Exp $
+#
+# Platform-specific parameters may be set in the appropriate .cf
+# configuration files.  Site-wide parameters may be set in the file
+# site.def.  Full rebuilds are recommended if any parameters are changed.
+#
+# If your C preprocessor doesn't define any unique symbols, you'll need
+# to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing
+# "make Makefile", "make Makefiles", or "make World").
+#
+# If you absolutely can't get imake to work, you'll need to set the
+# variables at the top of each Makefile as well as the dependencies at the
+# bottom (makedepend will do this automatically).
+#
+
+###########################################################################
+# platform-specific configuration parameters - edit sun.cf to change
+
+# platform:  $XConsortium: sun.cf,v 1.38 89/12/23 16:10:10 jim Exp $
+# operating system:  SunOS 4.0.3
+
+###########################################################################
+# site-specific configuration parameters - edit site.def to change
+
+            SHELL = /bin/sh
+
+              TOP = .
+      CURRENT_DIR = .
+
+               AR = ar clq
+  BOOTSTRAPCFLAGS =
+               CC = cc
+
+         COMPRESS = compress
+              CPP = /lib/cpp $(STD_CPP_DEFINES)
+    PREPROCESSCMD = cc -E $(STD_CPP_DEFINES)
+          INSTALL = install
+               LD = ld
+             LINT = lint
+      LINTLIBFLAG = -C
+         LINTOPTS = -axz
+               LN = ln -s
+             MAKE = make
+               MV = mv
+               CP = cp
+           RANLIB = ranlib
+  RANLIBINSTFLAGS =
+               RM = rm -f
+     STD_INCLUDES =
+  STD_CPP_DEFINES =
+      STD_DEFINES =
+ EXTRA_LOAD_FLAGS =
+  EXTRA_LIBRARIES =
+             TAGS = ctags
+
+    SHAREDCODEDEF = -DSHAREDCODE
+         SHLIBDEF = -DSUNSHLIB
+
+    PROTO_DEFINES =
+
+     INSTPGMFLAGS =
+
+     INSTBINFLAGS = -m 0755
+     INSTUIDFLAGS = -m 4755
+     INSTLIBFLAGS = -m 0664
+     INSTINCFLAGS = -m 0444
+     INSTMANFLAGS = -m 0444
+     INSTDATFLAGS = -m 0444
+    INSTKMEMFLAGS = -m 4755
+
+          DESTDIR =
+
+     TOP_INCLUDES = -I$(INCROOT)
+
+      CDEBUGFLAGS = -O
+        CCOPTIONS =
+      COMPATFLAGS =
+
+      ALLINCLUDES = $(STD_INCLUDES) $(TOP_INCLUDES) $(INCLUDES) $(EXTRA_INCLUDES)
+       ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(PROTO_DEFINES) $(DEFINES) $(COMPATFLAGS)
+           CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES)
+        LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES)
+           LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
+        LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS)
+   LDCOMBINEFLAGS = -X -r
+
+        MACROFILE = sun.cf
+           RM_CMD = $(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut
+
+    IMAKE_DEFINES =
+
+         IRULESRC = $(CONFIGDIR)
+        IMAKE_CMD = $(IMAKE) -DUseInstalled -I$(IRULESRC) $(IMAKE_DEFINES)
+
+     ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \
+			$(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \
+			$(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES)
+
+###########################################################################
+# X Window System Build Parameters
+# $XConsortium: Project.tmpl,v 1.63 89/12/18 16:46:44 jim Exp $
+
+###########################################################################
+# X Window System make variables; this need to be coordinated with rules
+# $XConsortium: Project.tmpl,v 1.63 89/12/18 16:46:44 jim Exp $
+
+          PATHSEP = /
+        USRLIBDIR = $(DESTDIR)/usr/lib
+           BINDIR = $(DESTDIR)/usr/bin/X11
+          INCROOT = $(DESTDIR)/usr/include
+     BUILDINCROOT = $(TOP)
+      BUILDINCDIR = $(BUILDINCROOT)/X11
+      BUILDINCTOP = ..
+           INCDIR = $(INCROOT)/X11
+           ADMDIR = $(DESTDIR)/usr/adm
+           LIBDIR = $(USRLIBDIR)/X11
+        CONFIGDIR = $(LIBDIR)/config
+       LINTLIBDIR = $(USRLIBDIR)/lint
+
+          FONTDIR = $(LIBDIR)/fonts
+         XINITDIR = $(LIBDIR)/xinit
+           XDMDIR = $(LIBDIR)/xdm
+           AWMDIR = $(LIBDIR)/awm
+           TWMDIR = $(LIBDIR)/twm
+           GWMDIR = $(LIBDIR)/gwm
+          MANPATH = $(DESTDIR)/usr/man
+    MANSOURCEPATH = $(MANPATH)/man
+           MANDIR = $(MANSOURCEPATH)n
+        LIBMANDIR = $(MANSOURCEPATH)3
+      XAPPLOADDIR = $(LIBDIR)/app-defaults
+
+        SOXLIBREV = 4.2
+          SOXTREV = 4.0
+         SOXAWREV = 4.0
+        SOOLDXREV = 4.0
+         SOXMUREV = 4.0
+        SOXEXTREV = 4.0
+
+       FONTCFLAGS = -t
+
+     INSTAPPFLAGS = $(INSTDATFLAGS)
+
+            IMAKE = imake
+           DEPEND = makedepend
+              RGB = rgb
+            FONTC = bdftosnf
+        MKFONTDIR = mkfontdir
+        MKDIRHIER = /bin/sh $(BINDIR)/mkdirhier.sh
+
+        CONFIGSRC = $(TOP)/config
+        CLIENTSRC = $(TOP)/clients
+          DEMOSRC = $(TOP)/demos
+           LIBSRC = $(TOP)/lib
+          FONTSRC = $(TOP)/fonts
+       INCLUDESRC = $(TOP)/X11
+        SERVERSRC = $(TOP)/server
+          UTILSRC = $(TOP)/util
+        SCRIPTSRC = $(UTILSRC)/scripts
+       EXAMPLESRC = $(TOP)/examples
+       CONTRIBSRC = $(TOP)/../contrib
+           DOCSRC = $(TOP)/doc
+           RGBSRC = $(TOP)/rgb
+        DEPENDSRC = $(UTILSRC)/makedepend
+         IMAKESRC = $(CONFIGSRC)
+         XAUTHSRC = $(LIBSRC)/Xau
+          XLIBSRC = $(LIBSRC)/X
+           XMUSRC = $(LIBSRC)/Xmu
+       TOOLKITSRC = $(LIBSRC)/Xt
+       AWIDGETSRC = $(LIBSRC)/Xaw
+       OLDXLIBSRC = $(LIBSRC)/oldX
+      XDMCPLIBSRC = $(LIBSRC)/Xdmcp
+      BDFTOSNFSRC = $(FONTSRC)/bdftosnf
+     MKFONTDIRSRC = $(FONTSRC)/mkfontdir
+     EXTENSIONSRC = $(TOP)/extensions
+
+  DEPEXTENSIONLIB =
+     EXTENSIONLIB = -lXext
+
+          DEPXLIB = $(DEPEXTENSIONLIB)
+             XLIB = $(EXTENSIONLIB) -lX11
+
+      DEPXAUTHLIB = $(USRLIBDIR)/libXau.a
+         XAUTHLIB =  -lXau
+
+        DEPXMULIB =
+           XMULIB = -lXmu
+
+       DEPOLDXLIB =
+          OLDXLIB = -loldX
+
+      DEPXTOOLLIB =
+         XTOOLLIB = -lXt
+
+        DEPXAWLIB =
+           XAWLIB = -lXaw
+
+ LINTEXTENSIONLIB = $(USRLIBDIR)/llib-lXext.ln
+         LINTXLIB = $(USRLIBDIR)/llib-lX11.ln
+          LINTXMU = $(USRLIBDIR)/llib-lXmu.ln
+        LINTXTOOL = $(USRLIBDIR)/llib-lXt.ln
+          LINTXAW = $(USRLIBDIR)/llib-lXaw.ln
+
+          DEPLIBS = $(DEPXAWLIB) $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB)
+
+         DEPLIBS1 = $(DEPLIBS)
+         DEPLIBS2 = $(DEPLIBS)
+         DEPLIBS3 = $(DEPLIBS)
+
+###########################################################################
+# Imake rules for building libraries, programs, scripts, and data files
+# rules:  $XConsortium: Imake.rules,v 1.67 89/12/18 17:14:15 jim Exp $
+
+###########################################################################
+# start of Imakefile
+
+#  Make WWW under unix for a.n.other unix system (bsd)
+#   Use this as a template
+
+TK_WWW_SOURCE_PATH=/a/dxcern/userd/tbl/hypertext/WWW/TkWWW/Tcl
+
+TK_WWW_INSTALL_PATH=/a/dxcern/userd/tbl/hypertext/WWW/TkWWW/$(WWW_MACH)
+
+TK_WWW_HOME_PAGE=http://www.w3.org/default.html
+TK_WWW_START_PAGE=$(TK_WWW_HOME_PAGE)
+
+CC = gcc -fno-builtin -Wall
+
+CDEBUGFLAGS = -O3 -pipe
+
+COMPATFLAGS =   -I/afs/athena.mit.edu/course/other/cdsdev/www-compat
+CCOPTIONS =
+
+BINDIR = $(TK_WWW_INSTALL_PATH)
+
+# For W3 distribution, machine type for subdirectories
+WWW_MACH = unix_x
+
+# The ASIS repository's name for the machine we are on
+ASIS_MACH = hardware/os
+
+#_________________ OK if normal W3 distribution
+# Where is the WWW source root?
+WWW = ../..
+
+#  Where should temporary (object) files go?
+WTMP = /tmp
+
+#	Common Makefile for W3 Library Code
+#	-----------------------------------
+#
+#	(c) CERN 1990, 1991 -- see Copyright.html for conditions
+#
+# This file should be invariant between systems.
+#	DEPENDENCIES NOT COMPLETE
+
+#
+#	make		Compile and link the software (private version)
+#	make clean	Remove intermediate files
+
+WC = $(WWW)/Library
+CMN = $(WWW)/Library/Implementation/
+
+# Where shall we put the objects and built library?
+
+LOB = $(WTMP)/Library/$(WWW_MACH)
+
+# Bug: This path, if relative, is taken relative to the directory
+# in which this makefile is, not the pwd.  This screws up the
+# recursive invocation
+
+VC = 2.14
+
+CFLAGS2 = $(CFLAGS) -I$(CMN)
+
+CERNLIBBIN = $(WWW)/bin
+
+COMMON = $(LOB)/HTParse.o $(LOB)/HTAccess.o $(LOB)/HTTP.o \
+	$(LOB)/HTFile.o	$(LOB)/HTFTP.o $(LOB)/HTTCP.o \
+	$(LOB)/SGML.o $(LOB)/HTMLDTD.o $(LOB)/HTChunk.o \
+	$(LOB)/HTPlain.o $(LOB)/HTWriter.o $(LOB)/HTFWriter.o \
+	$(LOB)/HTMLGen.o \
+	$(LOB)/HTAtom.o $(LOB)/HTAnchor.o $(LOB)/HTStyle.o \
+	$(LOB)/HTList.o $(LOB)/HTString.o $(LOB)/HTAlert.o \
+	$(LOB)/HTRules.o $(LOB)/HTFormat.o $(LOB)/HTInit.o $(LOB)/HTMIME.o \
+	$(LOB)/HTHistory.o $(LOB)/HTNews.o $(LOB)/HTGopher.o \
+	$(LOB)/HTTelnet.o  $(LOB)/HTWSRC.o $(HTWAIS)
+
+CFILES = $(CMN)HTParse.c $(CMN)HTAccess.c $(CMN)HTTP.c $(CMN)HTFile.c \
+	$(CMN)HTFTP.c   $(CMN)HTTCP.c     $(CMN)SGML.c	\
+	$(CMN)HTMLDTD.c \
+	$(CMN)HTPlain.c	$(CMN)HTWriter.c  $(CMN)HTFWriter.c $(CMN)HTMLGen.c	\
+	$(CMN)HTChunk.c $(CMN)HTAtom.c   $(CMN)HTAnchor.c $(CMN)HTStyle.c \
+	$(CMN)HTList.c  $(CMN)HTString.c $(CMN)HTAlert.c $(CMN)HTRules.c \
+	$(CMN)HTFormat.c $(CMN)HTInit.c $(CMN)HTMIME.c $(CMN)HTHistory.c \
+	$(CMN)HTNews.c  $(CMN)HTGopher.c $(CMN)HTTelnet.c \
+	$(CMN)HTWAIS.c  $(CMN)HTWSRC.c
+
+HFILES = $(CMN)HTParse.h $(CMN)HTAccess.h $(CMN)HTTP.h $(CMN)HTFile.h \
+	$(CMN)HTFTP.h $(CMN)HTTCP.h \
+	$(CMN)SGML.h $(CMN)HTML.h $(CMN)HTMLDTD.h $(CMN)HTChunk.h \
+	$(CMN)HTPlain.h		$(CMN)HTWriter.h \
+	$(CMN)HTFWriter.h 	$(CMN)HTMLGen.h	\
+	$(CMN)HTStream.h \
+	$(CMN)HTAtom.h $(CMN)HTAnchor.h $(CMN)HTStyle.h \
+	$(CMN)HTList.h \
+	$(CMN)HTString.h $(CMN)HTAlert.h $(CMN)HTRules.h \
+	$(CMN)HTFormat.h $(CMN)HTInit.h \
+	$(CMN)HTMIME.h $(CMN)HTHistory.h $(CMN)HTNews.h \
+	$(CMN)HTGopher.h \
+	$(CMN)HTUtils.h $(CMN)tcp.h $(CMN)WWW.h $(CMN)HText.h \
+	$(CMN)HTTelnet.h \
+	$(CMN)HTWAIS.h  $(CMN)HTWSRC.h
+
+SOURCES = $(CFILES) $(HFILES) $(CMN)Version.make $(CMN)CommonMakefile \
+	$(WWW)/README.txt $(WWW)/Copyright.txt $(WWW)/BUILD
+SPECIFIC = $(WWW)/All
+
+#	Library
+#
+#  On SGI, ranlib is unnecessary and does not exist so we ignore errors
+# for that step
+all: $(LOB)/libwww.a
+	$(MV) $(LOB)/libwww.a $(WC)/$(WWW_MACH)
+
+$(LOB)/libwww.a : $(COMMON)
+	ar r $(LOB)/libwww.a $(COMMON)
+	-ranlib $(LOB)/libwww.a
+
+#	Clean up everything generatable except final products
+clean ::
+	$(RM) $(LOB)
+
+#	Clean up everything generatable including final products
+
+cleanall :: clean
+	$(RM) $(LOB)/libwww.a
+
+# 			Common code
+#			-----------
+
+#	Directory for object files - .created checks it exists
+
+OE = $(LOB)/.created
+$(OE) :
+	-mkdir $(WTMP)
+	-mkdir $(WTMP)/Library
+	-mkdir $(WTMP)/Library/$(WWW_MACH)
+	touch $@
+
+$(LOB)/HTList.o : $(OE) $(CMN)HTList.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTList.c
+
+$(LOB)/HTAnchor.o : $(OE) $(CMN)HTAnchor.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTAnchor.c
+
+$(LOB)/HTFormat.o : $(OE) $(CMN)HTFormat.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTFormat.c
+
+$(LOB)/HTInit.o : $(OE) $(CMN)HTInit.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTInit.c
+
+$(LOB)/HTMIME.o : $(OE) $(CMN)HTMIME.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTMIME.c
+
+$(LOB)/HTHistory.o : $(OE) $(CMN)HTHistory.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTHistory.c
+
+$(LOB)/HTNews.o : $(OE) $(CMN)HTNews.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTNews.c
+
+$(LOB)/HTGopher.o : $(OE) $(CMN)HTGopher.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTGopher.c
+
+$(LOB)/HTTelnet.o : $(OE) $(CMN)HTTelnet.c $(CMN)HTUtils.h $(CMN)HTTelnet.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTTelnet.c
+
+$(LOB)/HTStyle.o : $(OE) $(CMN)HTStyle.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTStyle.c
+
+$(LOB)/HTAtom.o : $(OE) $(CMN)HTAtom.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTAtom.c
+
+$(LOB)/HTChunk.o : $(OE) $(CMN)HTChunk.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTChunk.c
+
+$(LOB)/HTString.o : $(OE) $(CMN)HTString.c $(CMN)HTUtils.h $(CMN)Version.make
+	$(CC) -c -o $@ $(CFLAGS2) -DVC=\"$(VC)\" $(CMN)HTString.c
+
+$(LOB)/HTAlert.o : $(OE) $(CMN)HTAlert.c $(CMN)HTUtils.h $(CMN)Version.make
+	$(CC) -c -o $@ $(CFLAGS2) -DVC=\"$(VC)\" $(CMN)HTAlert.c
+
+$(LOB)/HTRules.o : $(OE) $(CMN)HTRules.c $(CMN)HTUtils.h $(CMN)Version.make
+	$(CC) -c -o $@ $(CFLAGS2) -DVC=\"$(VC)\" $(CMN)HTRules.c
+
+$(LOB)/SGML.o : $(OE) $(CMN)SGML.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)SGML.c
+
+$(LOB)/HTMLGen.o : $(OE) $(CMN)HTMLGen.c $(CMN)HTUtils.h $(CMN)HTMLDTD.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTMLGen.c
+
+$(LOB)/HTMLDTD.o : $(OE) $(CMN)HTMLDTD.c $(CMN)SGML.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTMLDTD.c
+
+$(LOB)/HTPlain.o : $(OE) $(CMN)HTPlain.c $(CMN)HTPlain.h $(CMN)HTStream.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTPlain.c
+
+$(LOB)/HTWAIS.o : $(OE) $(CMN)HTWAIS.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(WAISINC) $(CMN)HTWAIS.c
+
+$(LOB)/HTWSRC.o : $(OE) $(CMN)HTWSRC.c $(CMN)HTUtils.h $(CMN)HTList.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTWSRC.c
+
+$(LOB)/HTWriter.o : $(OE) $(CMN)HTWriter.c $(CMN)HTWriter.h $(CMN)HTStream.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTWriter.c
+
+$(LOB)/HTFWriter.o : $(OE) $(CMN)HTFWriter.c $(CMN)HTFWriter.h $(CMN)HTStream.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTFWriter.c
+
+#	Communications & Files
+
+$(LOB)/HTTP.o : $(OE) $(CMN)HTTP.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTTP.c
+
+$(LOB)/HTTCP.o : $(OE) $(CMN)HTTCP.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTTCP.c
+
+$(LOB)/HTFile.o : $(OE) $(CMN)HTFile.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTFile.c
+
+$(LOB)/HTFTP.o : $(OE) $(CMN)HTFTP.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTFTP.c
+
+$(LOB)/HTAccess.o : $(OE)  $(CMN)HTAccess.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTAccess.c
+
+$(LOB)/HTParse.o : $(OE) $(CMN)HTParse.c $(CMN)HTUtils.h
+	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTParse.c
+
+###########################################################################
+# common rules for all Makefiles - do not edit
+
+emptyrule::
+
+clean::
+	$(RM_CMD) \#*
+
+Makefile::
+	-@if [ -f Makefile ]; then \
+	echo "	$(RM) Makefile.bak; $(MV) Makefile Makefile.bak"; \
+	$(RM) Makefile.bak; $(MV) Makefile Makefile.bak; \
+	else exit 0; fi
+	$(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)
+
+tags::
+	$(TAGS) -w *.[ch]
+	$(TAGS) -xw *.[ch] > TAGS
+
+saber:
+	#load $(ALLDEFINES) $(SRCS)
+
+osaber:
+	#load $(ALLDEFINES) $(OBJS)
+
+###########################################################################
+# empty rules for directories that do not have SUBDIRS - do not edit
+
+install::
+	@echo "install in $(CURRENT_DIR) done"
+
+install.man::
+	@echo "install.man in $(CURRENT_DIR) done"
+
+Makefiles::
+
+includes::
+
+###########################################################################
+# dependencies generated by makedepend
+
diff --git a/WWW/Library/Implementation/SGML.c b/WWW/Library/Implementation/SGML.c
index 2a210561..c2cadecd 100644
--- a/WWW/Library/Implementation/SGML.c
+++ b/WWW/Library/Implementation/SGML.c
@@ -479,7 +479,7 @@ PRIVATE void handle_comment ARGS1(
 
     if (context->csi == NULL &&
         strncmp(s, "!--#", 4) == 0 &&
-        LYCheckForCSI(context->target, (char **)&context->url) == TRUE) {
+        LYCheckForCSI(context->node_anchor, (char **)&context->url) == TRUE) {
 	LYDoCSI(context->url, s, (char **)&context->csi);
     }
 
diff --git a/WWW/Library/Implementation/SGML.h b/WWW/Library/Implementation/SGML.h
index 0799c055..d8f90c19 100644
--- a/WWW/Library/Implementation/SGML.h
+++ b/WWW/Library/Implementation/SGML.h
@@ -222,10 +222,11 @@ typedef struct _HTStructuredClass{
 }HTStructuredClass;
 
 /*
-  The following functions possibly should be generalised into
-  additional HTStructuredClass memebers. - kw
+  Equivalents to the following functions possibly could be generalised
+  into additional HTStructuredClass members.  FOr now they don't do
+  anything target-specific. - kw
   */
-extern BOOLEAN LYCheckForCSI PARAMS((HTStructured *target, char **url));
+extern BOOLEAN LYCheckForCSI PARAMS((HTParentAnchor *anchor, char **url));
 extern void LYDoCSI PARAMS((char *url, CONST char *comment, char **csi));
 
 /*
diff --git a/WWW/Library/Implementation/UCAux.h b/WWW/Library/Implementation/UCAux.h
index a21521c4..36c17050 100644
--- a/WWW/Library/Implementation/UCAux.h
+++ b/WWW/Library/Implementation/UCAux.h
@@ -53,6 +53,13 @@ extern void UCSetTransParams PARAMS((
 extern void UCTransParams_clear PARAMS((
 	UCTransParams *		pT));
 
+extern void UCSetBoxChars PARAMS((
+    int		cset,
+    int *	pvert_out,
+    int *	phori_out,
+    int		vert_in,
+    int		hori_in));
+
 #ifndef HTSTREAM_H
 #include "HTStream.h"
 #endif /* HTSTREAM_H */
diff --git a/WWW/Library/djgpp/CommonMakefile b/WWW/Library/djgpp/CommonMakefile
index 8543aaf3..1fdaf314 100644
--- a/WWW/Library/djgpp/CommonMakefile
+++ b/WWW/Library/djgpp/CommonMakefile
@@ -146,7 +146,7 @@ $(LOB)/libwww.a : $(COMMON)
 
 #	Clean up everything generatable except final products
 clean :
-	rm $(LOB)/*.o $(LOB)/created
+	rm $(LOB)/*.o 
 	-rmdir $(LOB)
 
 #	Clean up everything generatable including final products
@@ -212,15 +212,7 @@ $(WWW)/Copyright.txt : $(WWW)/../Copyright.html
 # 			Common code
 #			-----------
 
-#	Directory for object files - created checks it exists
-
-OE = $(LOB)/created
-$(OE) :
-	if [ ! -r $(WTMP) ] ; then mkdir $(WTMP); else echo OK ; fi
-	if [ ! -r $(WTMP)/Library ] ; then mkdir $(WTMP)/Library; else echo OK ; fi
-	if [ ! -r $(WTMP)/Library/$(WWW_MACH) ] ; \
-		then mkdir $(WTMP)/Library/$(WWW_MACH); else echo OK ; fi
-	touch $@
+#	Directory for object files
 
 $(LOB)/HTList.o : $(OE) $(CMN)HTList.c $(CMN)HTUtils.h $(CMN)HTList.h
 	$(CC) -c -o $@ $(CFLAGS2) $(CMN)HTList.c
diff --git a/WWW/Library/djgpp/makefile b/WWW/Library/djgpp/makefile
index cf37f9f1..103b4c04 100644
--- a/WWW/Library/djgpp/makefile
+++ b/WWW/Library/djgpp/makefile
@@ -7,7 +7,8 @@ WWW_MACH = djgpp
 # The ASIS repository's name for the machine we are on
 #ASIS_MACH = hardware/os
 
-CFLAGS = -O3 -DEXP_CHARTRANS -DCOLOR_CURSES -DDOSPATH -DNOUSERS -DDEBUG -I../../../djgpp/tcplib/include -I../../../djgpp/tcplib/include/tcp
+CFLAGS = -O3 -DUSE_ZLIB -DEXP_CHARTRANS -DDOSPATH -DNOUSERS -DDEBUG -I../../../djgpp/tcplib/include -I../../../djgpp/tcplib/include/tcp \
+-I../../../src -I../../..
 LFLAGS =
 CC = gcc
 
diff --git a/WWW/Library/unix/Makefile.old b/WWW/Library/unix/Makefile.old
new file mode 100644
index 00000000..5fea7dd7
--- /dev/null
+++ b/WWW/Library/unix/Makefile.old
@@ -0,0 +1,30 @@
+#  Make WWW under unix for a.n.other unix system (bsd)
+#   Use this as a template
+
+# For W3 distribution, machine type for subdirectories
+WWW_MACH = unix
+
+# The ASIS repository's name for the machine we are on
+ASIS_MACH = hardware/os
+
+
+CFLAGS =  -g -DDEBUG
+LFLAGS =
+CC = cc
+
+# Directory for installed binary:
+BINDIR = /usr/local/bin
+
+# Where is the W3 object library to be installed (not normally done)?
+LIBDIR = $(WWW)/Library/Implementation/$(WWW_MACH)
+
+#_________________ OK if normal W3 distribution
+# Where is the WWW source root?
+WWW = ../..
+
+#  Where should temporary (object) files go?
+WTMP = ../..
+
+
+include $(WWW)/Library/Implementation/Version.make
+include $(WWW)/Library/Implementation/CommonMakefile