lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

LYNX-DEV LINK REL=xxx patch (a bit long)


From: Benjamin C. W. Sittler
Subject: LYNX-DEV LINK REL=xxx patch (a bit long)
Date: Sat, 21 Dec 1996 23:11:28 -0700 (MST)

This patch is against Lynx 2.6 with Fote's 1996.12.20 mods. I wrote it
after reading the (now expired) draft-ietf-html-relrev-00.txt, which
discusses the LINK and Anchor attributes. According to this draft,
Forward, Back, and Home are reserved for browser internal use!

If you wish to conform to this draft (still cited in HTML 3.2 as the
reference LINK REL and REV values!) I suggest you change Forward to Next,
Back to Previous, Home to Top, Up to Parent, and Help to Navigator.

*** lynx2-6/src/HTML.c.old      Sun Dec 15 16:13:34 1996
--- lynx2-6/src/HTML.c  Sat Dec 21 21:59:43 1996
***************
*** 675,695 ****
                }
  
                /*
                 *  Ignore anything not registered as of 28-Mar-95
                 *  IETF specs.  We'll make this more efficient when
                 *  the situation stabilizes, and for now, we'll treat
                 *  "Banner" as another toolbar element. - FM
                 */
!               if (strcasecomp(value[HTML_LINK_REL], "Home") &&
                    strcasecomp(value[HTML_LINK_REL], "ToC") &&
                    strcasecomp(value[HTML_LINK_REL], "Index") &&
                    strcasecomp(value[HTML_LINK_REL], "Glossary") &&
                    strcasecomp(value[HTML_LINK_REL], "Copyright") &&
!                   strcasecomp(value[HTML_LINK_REL], "Up") &&
                    strcasecomp(value[HTML_LINK_REL], "Next") &&
                    strcasecomp(value[HTML_LINK_REL], "Previous") &&
!                   strcasecomp(value[HTML_LINK_REL], "Help") &&
                    strcasecomp(value[HTML_LINK_REL], "Bookmark") &&
                    strcasecomp(value[HTML_LINK_REL], "Banner")) {
                    if (TRACE) {
                        fprintf(stderr,
--- 675,737 ----
                }
  
                /*
+                * Ignore browser-reserved links. -BCWS
+                */
+               if (!(strcasecomp(value[HTML_LINK_REL], "Home") &&
+                     strcasecomp(value[HTML_LINK_REL], "Back") &&
+                     strcasecomp(value[HTML_LINK_REL], "Forward")
+                     )){
+                   if (TRACE) {
+                       fprintf(stderr,
+                               "HTML.c: Browser-reserved '%s' link found -- 
ignoring.\n",
+                               value[HTML_LINK_REL]);
+                   }
+                   FREE(href);
+                   break;
+               }
+ 
+               /*
                 *  Ignore anything not registered as of 28-Mar-95
                 *  IETF specs.  We'll make this more efficient when
                 *  the situation stabilizes, and for now, we'll treat
                 *  "Banner" as another toolbar element. - FM
+                *
+                *  Changed to reflect the now-expired 
draft-ietf-html-relrev-00.txt
+                *  which is still (as of 1996.12.21) available at ALTERNIC.NET:
+                *    
http://www.alternic.net/rfcs/draft-ietf-html-relrev-00.txt.html
+                *  This means existing HOME, UP and HELP links no longer work.
+                *  It also means we get the navigation sequence links 
(BEGIN/FIRST,
+                *  END/LAST, NEXT, PREVIOUS/PREV) and many others. -BCWS
                 */
!               if (strcasecomp(value[HTML_LINK_REL], "Top") &&
!                   strcasecomp(value[HTML_LINK_REL], "Origin") &&
                    strcasecomp(value[HTML_LINK_REL], "ToC") &&
+                   strcasecomp(value[HTML_LINK_REL], "Contents") &&
+                   strcasecomp(value[HTML_LINK_REL], "Navigator") &&
+                   strcasecomp(value[HTML_LINK_REL], "Child") &&
                    strcasecomp(value[HTML_LINK_REL], "Index") &&
                    strcasecomp(value[HTML_LINK_REL], "Glossary") &&
                    strcasecomp(value[HTML_LINK_REL], "Copyright") &&
!                   strcasecomp(value[HTML_LINK_REL], "Disclaimer") &&
!                   strcasecomp(value[HTML_LINK_REL], "Sibling") &&
!                   strcasecomp(value[HTML_LINK_REL], "Parent") &&
                    strcasecomp(value[HTML_LINK_REL], "Next") &&
                    strcasecomp(value[HTML_LINK_REL], "Previous") &&
!                   strcasecomp(value[HTML_LINK_REL], "Prev") &&
!                   strcasecomp(value[HTML_LINK_REL], "Author") &&
!                   strcasecomp(value[HTML_LINK_REL], "Editor") &&
!                   strcasecomp(value[HTML_LINK_REL], "Publisher") &&
!                   strcasecomp(value[HTML_LINK_REL], "Trademark") &&
!                   strcasecomp(value[HTML_LINK_REL], "Meta") &&
                    strcasecomp(value[HTML_LINK_REL], "Bookmark") &&
+                   strcasecomp(value[HTML_LINK_REL], "Begin") &&
+                   strcasecomp(value[HTML_LINK_REL], "First") &&
+                   strcasecomp(value[HTML_LINK_REL], "End") &&
+                   strcasecomp(value[HTML_LINK_REL], "Last") &&
+                   strcasecomp(value[HTML_LINK_REL], "Pointer") &&
+                   strcasecomp(value[HTML_LINK_REL], "Translation") &&
+                   strcasecomp(value[HTML_LINK_REL], "Glossary") &&
+                   strcasecomp(value[HTML_LINK_REL], "Bibliography") &&
                    strcasecomp(value[HTML_LINK_REL], "Banner")) {
                    if (TRACE) {
                        fprintf(stderr,


;
; To UNSUBSCRIBE:  Send a mail message to address@hidden
;                  with "unsubscribe lynx-dev" (without the
;                  quotation marks) on a line by itself.
;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]