[Top][All Lists]

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

Re: wget, & and lynx (was Re: lynx-dev bug report)

From: Klaus Weide
Subject: Re: wget, & and lynx (was Re: lynx-dev bug report)
Date: Mon, 25 Oct 1999 15:56:43 -0500 (CDT)

On Mon, 25 Oct 1999, Leonid Pauzner wrote:

> 25-Oct-99 11:20 Oliver Seidel wrote:
> > -rw-r--r--   1 os10000  private      3689 Oct 25 11:10 
> > forum_reply?keepcookie=0&lm=854576442
> > <TABLE>
> > <TR><TD><A HREF="../forum_reply?keepcookie=0&amp;lm=854576442">How much 
> > wood would a wood chuck ch...</A><TD>1 day old<TD>(last of 9 replies 998 
> > days ago)</TR>
> That make me some sence:
> 2) lynx is wrong since do translate entities for local file names
> appeared from directory listing (not one embeded into HTML).

Nothing in the example shown were lynx-generated.

Lynx does not generate URLs for local files with unescaped "&" characters,
as far as I know.  At least not on Unix.  I don't trust what folks are
doing on Windows in this respect, but then I don't have to use it...

> Such symbol as "&" should be added for HTEscapeSome() call
> along with "/", "#" and "%" in this particular directory context.

Show an example where lynx does the wrong thing before considering how
to fix it.

I spent some time getting the level of escaping/unescaping right for
local files, icluding for dired menu actions, it should work for
strange filenames (and hopefully even directory names) containing
strange characters and combinations.  For example a file
"./%backup%dir/%bac#up%".  I hope you're not telling me it is
broken again...

Luckily there is no HTEscapeSome function, HTUnEscapeSome is bad enough
as a crutch.  A HTEscapeSome function would almost certainly be wrong,
for whateve purpose one might want to use it...

> >From the other hand, I have a feeling that "&" symbol may be deprecated
> in filename on some OSes.

That doesn't really matter for how to present it in a URL.

> (*) Also, I know it from my experience, if someone serve a file
> named as "a&b.html" via HTTP and supply a link <A href="a&amp;b.html">
> from another document, wget failed to download this file
> since trying to access "a&amp;b.html" in fact.
> A real life example from Apache log file:
>  - - [19/Sep/1999:10:54:15 +0200] "GET /tv-b&amp;o.htm HTTP/1.0" 404 212
> 404 = file not exist, and this is wget.
> A workaround such rewriting the link as <a href="tv-b%24o.htm">

YM href="tv-b%26o.htm"

That's not a workaround but the more correct URL, if "tv-b&o.htm" is
just a filename on the server's file system.


reply via email to

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