Commits

adriana  committed 759c0d6

[xemacsweb PATCH] Fixing links in http://xemacs.sourceforge.net/... <uvgxc95ur.fsf@ecf.teradyne.com>

  • Participants
  • Parent commits 29cb1b7

Comments (0)

Files changed (4)

File FAQ/index.content

 <P><HR><P>
 -->
 
-<H1><A NAME="SEC1" HREF="faq/xemacs-faq_toc.html#TOC1">Introduction</A></H1>
+<H1><A NAME="SEC1" HREF="xemacs-faq_toc.html#TOC1">Introduction</A></H1>
 <P>
 This is the guide to the XEmacs Frequently Asked Questions list--a
 compendium of questions and answers pertaining to one of the finest
 This document is available in several different formats:
 <UL>
 <LI>
-<A HREF="faq/xemacs-faq.txt">As a single ASCII file</A>, produced by
+<A HREF="xemacs-faq.txt">As a single ASCII file</A>, produced by
 <CODE>makeinfo --no-headers</CODE>
 <LI>
-<A HREF="faq/xemacs-faq.dvi">As a .dvi file</A>, as used with
+<A HREF="xemacs-faq.dvi">As a .dvi file</A>, as used with
 <A HREF="http://www.tug.org">TeX.</A>
 <!--
 <LI>
 as well as in <A HREF="xemacs-faq-letter.ps">letter format</A>
 -->
 <LI>
-In html format, <A HREF="faq/xemacs-faq_2.html">split by chapter</A>, or in
-<A HREF="faq/xemacs-faq.html">one monolithic</A> document.
+In html format, <A HREF="xemacs-faq_2.html">split by chapter</A>, or in
+<A HREF="xemacs-faq.html">one monolithic</A> document.
 <LI>
 The canonical version of the FAQ is the texinfo document
-<A HREF="faq/xemacs-faq.texi">man/xemacs-faq.texi</A>.
+<A HREF="xemacs-faq.texi">man/xemacs-faq.texi</A>.
 <!--
 You'll need
 <A HREF="mswindows-faq.texi">man/mswindows-faq.texi</A> as well.
 </UL>
 <!--
 <P><HR><P>
-Go to the first, previous, <A HREF="faq/xemacs-faq_2.html">next</A>, <A HREF="xemacs-faq_8.html">last</A> section, <A HREF="xemacs-faq_toc.html">table of contents</A>.
+Go to the first, previous, <A HREF="xemacs-faq_2.html">next</A>, <A HREF="xemacs-faq_8.html">last</A> section, <A HREF="xemacs-faq_toc.html">table of contents</A>.
 >

File genpage.conf

 evalparam	=
 execute		=
 includedir	= .
-recipes		= toc.gp
+libdir      = genpage/lib
+recipes		= relPath.gp

File genpage/lib/relPath.gp

 
 	$outdir =~ s/\/\//\//g;		# substitute // with /
 	$outfile =~ s/\/\//\//g;
-
-	$outfile =~ s|$outdir||g;
+    # APA: quote possible meta characters '\' in $outdir!
+    my $outdirpat = quotemeta("$outdir");
+	$outfile =~ s/$outdirpat//g;
 
 	# convert this filename into a relativ path to the root of the current
 	# directory hirarchy
 	# /index.html -> ./
 	# /abcdef/index.html -> ../
 	# /abcd/efg/index.html -> ../../
-
-	$outfile =~ s/[^\/]//g;	# remove all non '/' characters
-	chop($outfile);
-	$outfile =~ s/\//\.\.\//g;
-	$outfile = "./" . $outfile . $path;
+    #
+    # APA: Handle DOS path separators too.
+	$outfile =~ s/[^\/\\]//g;	# remove all non '/' and '\' characters
+	$outfile =~ s/[\/\\]/\.\.\//g;
+	$outfile = $outfile . $path;
 
 	return $outfile;
 }
 
-return ("<!-- Genpage recipe relPath included -->");
+return ("<!-- Genpage recipe relPath included -->");

File template.html

     <table border="0" cellspacing="0" cellpadding="0">
         <tr><!-- logo row -->
           <td align="left" valign="middle" colspan="6">
-            <img src="Images/xemacs.gif" alt="XEmacs -- Emacs: The Next Generation"
+            <img src="<!-- _GP_ relPath(qq{Images/xemacs.gif}) -->" alt="XEmacs -- Emacs: The Next Generation"
                  height="145" width="388" align="top">
-            <!--     <a href="Languages/Japanese/index.html">[Japanese]</a>  -->
           </td>
         </tr>
         <tr><!-- spacer row-->
-          <td colspan="3" bgcolor="#CCCCCC"><img src="Images/blank.gif" width="1" height="5" alt=""></td>
-          <td colspan="3"><img src="Images/blank.gif" width="1" height="5" alt=""></td>
+          <td colspan="3" bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="1" height="5" alt=""></td>
+          <td colspan="3"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="1" height="5" alt=""></td>
         </tr>
         <tr><!-- content row -->
           <!-- spacer cell -->
-          <td bgcolor="#CCCCCC"><img src="Images/blank.gif" width="10" height="1" alt=""></td>
+          <td bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="10" height="1" alt=""></td>
           <!-- sidebar cell -->
           <td align="left" valign="top" bgcolor="#CCCCCC">
-            <font size="3"><strong><a href="./index.html">www.xemacs.org</a></strong></font><br><br>
+            <font size="3"><strong><a href="<!-- _GP_ relPath(qq{index.html}) -->">www.xemacs.org</a></strong></font><br><br>
             <font size="3"><strong>Languages</strong></font><br>
             <font size="2">
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Languages/German/index.html">German</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Languages/Japanese/index.html">Japanese</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Languages/German/index.html}) -->">German</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Languages/Japanese/index.html}) -->">Japanese</a><br>
             </font>
             <br>
             <font size="3"><strong>About XEmacs</strong></font><br>
             <font size="2">
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="About/index.html">History of XEmacs</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="About/XEmacsVsGNUemacs.html">XEmacs vs. GNU Emacs</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="About/Screenshots/index.html">Screenshots</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="About/created.html">Sites Created With XEmacs</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="About/Y2Kstatement.html">Year 2000 Statement</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Develop/devTeam.html">Who Wrote XEmacs?</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{About/index.html}) -->">History of XEmacs</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{About/XEmacsVsGNUemacs.html}) -->">XEmacs vs. GNU Emacs</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{About/Screenshots/index.html}) -->">Screenshots</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{About/created.html}) -->">Sites Created With XEmacs</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{About/Y2Kstatement.html}) -->">Year 2000 Statement</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Develop/devTeam.html}) -->">Who Wrote XEmacs?</a><br>
             </font>
             <br>
             <font size="3"><strong>Getting XEmacs</strong></font><br>
             <font size="2">
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Download/index.html">Download</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Download/optLibs.html">Optional Libraries</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Install/index.html">Installation HOWTOs</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Documentation/index.html">Documentation</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Links/install.html">Installation resources</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Download/index.html}) -->">Download</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Download/optLibs.html}) -->">Optional Libraries</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Install/index.html}) -->">Installation HOWTOs</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Documentation/index.html}) -->">Documentation</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Links/install.html}) -->">Installation resources</a><br>
             </font>
             <br>
             <font size="3"><strong>Customizing XEmacs</strong></font><br>
             <font size="2">
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Download/elispPackages.html">Elisp packages</a><br>
-              <!-- <img src="Images/blank.gif" width="5" height="1" alt="">
-            <a href="Download/elispSites.html">Elisp sites</a><br> -->
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Links/customization.html">Customization resources</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Download/elispPackages.html}) -->">Elisp packages</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Links/customization.html}) -->">Customization resources</a><br>
             </font>
             <br>
             <font size="3"><strong>Troubleshooting XEmacs</strong></font><br>
             <font size="2">
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="FAQ/index.html">FAQ</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Lists/index.html">Mailing lists</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Lists/Archive/index.cgi">Mailing list archives</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Links/troubleshooting.html">Troubleshooting resources</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{FAQ/index.html}) -->">FAQ</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Lists/index.html}) -->">Mailing lists</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Lists/Archive/index.cgi}) -->">Mailing list archives</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Links/troubleshooting.html}) -->">Troubleshooting resources</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
               <a href="http://cvs.xemacs.org/XEmacs-bugs">Bug tracking system</a><br>
             </font> 
             <br>
             <font size="3"><strong>Developing XEmacs</strong></font><br>
             <font size="2">
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Develop/index.html">How to help</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Develop/devTeam.html">Who Wrote XEmacs?</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Develop/jobs.html">Dev team responsibilities</a><br>
-              <img src="Images/blank.gif" width="5" height="1" alt="">
-              <a href="Architecting-XEmacs/index.html">Architecting XEmacs</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Develop/index.html}) -->">How to help</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Develop/devTeam.html}) -->">Who Wrote XEmacs?</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Develop/jobs.html}) -->">Dev team responsibilities</a><br>
+              <img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt="">
+              <a href="<!-- _GP_ relPath(qq{Architecting-XEmacs/index.html}) -->">Architecting XEmacs</a><br>
             </font> 
           </td><!-- /sidebar cell -->
           <!-- two spacer cells -->
-          <td bgcolor="#CCCCCC"><img src="Images/blank.gif" width="5" height="1" alt=""></td>
-          <td><img src="Images/blank.gif" width="5" height="1" alt=""></td>
+          <td bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt=""></td>
+          <td><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="5" height="1" alt=""></td>
           <!-- content cell -->
           <td align="left" valign="top">
 
 
           </td><!-- /content cell -->
           <!-- spacer cell -->
-          <td><img src="Images/blank.gif" width="10" height="1" alt=""></td>
+          <td><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="10" height="1" alt=""></td>
         </tr>
         <tr><!-- spacer row -->
-          <td colspan="6" bgcolor="#CCCCCC"><img src="Images/blank.gif" width="1" height="5" alt=""></td></tr>
+          <td colspan="6" bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="1" height="5" alt=""></td></tr>
         <tr><!-- footer row -->
           <!-- spacer cell -->
-          <td bgcolor="#CCCCCC"><img src="Images/blank.gif" width="10" height="1" alt=""></td>
+          <td bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="10" height="1" alt=""></td>
           <!-- logo cell : flying the flag -->
           <td align="left" valign="bottom" bgcolor="#CCCCCC">
-            <a href="http://www.xemacs.org/About/created.html"><img src="Images/cbxSmall.jpg" width="100" height="36" border="0" alt="Made with XEmacs!"></a>
+            <a href="http://www.xemacs.org/About/created.html"><img src="<!-- _GP_ relPath(qq{Images/cbxSmall.jpg}) -->" width="100" height="36" border="0" alt="Made with XEmacs!"></a>
           </td>
           <!-- spacer cell -->
-          <td colspan="2" bgcolor="#CCCCCC"><img src="Images/blank.gif" width="10" height="1" alt=""></td>
+          <td colspan="2" bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="10" height="1" alt=""></td>
           <!-- footer info cell -->
           <td valign="top" align="right" bgcolor="#CCCCCC">
             <font size="2"><i>
               </i></font>
           </td><!-- /footer cell -->
           <!-- spacer cell -->
-          <td bgcolor="#CCCCCC"><img src="Images/blank.gif" width="10" height="1" alt=""></td>
+          <td bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="10" height="1" alt=""></td>
         </tr>
         <tr>
           <!-- spacer row -->
-          <td colspan="6" bgcolor="#CCCCCC"><img src="Images/blank.gif" width="1" height="10" alt=""></td></tr>
+          <td colspan="6" bgcolor="#CCCCCC"><img src="<!-- _GP_ relPath(qq{Images/blank.gif}) -->" width="1" height="10" alt=""></td></tr>
     </table>
   </body>
 </html>