[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Lynx-dev] loading incorrect webpage
From: |
Bela Lubkin |
Subject: |
Re: [Lynx-dev] loading incorrect webpage |
Date: |
Tue, 15 Nov 2022 13:22:48 -0800 |
"jindam, vani" wrote:
> probably meaningless, but urlencode was also giving incorrect results for:
>
> $ urlencode
> https://en.wikipedia.org/w/index.php?title=User:Jindam_vani/zandbak&action=history
>
> but it shows correct result:
>
> $ urlencode
> 'https://en.wikipedia.org/w/index.php?title=User:Jindam_vani/zandbak&action=history'
Not at all meaningless: it precisely shows the problem. The '&'
character is meaningful to the shell, and the first command does not
quote it. That command means:
1. Run 'urlencode
https://en.wikipedia.org/w/index.php?title=User:Jindam_vani/zandbak'
in the background
2. Immediately after launching that in the background, also run 'action=history'
in the foreground [ which will finish immediately, without error ]
This is standard Unix shell stuff. Quoting with 'single-quotes' is the
best approach -- assuming the thing you're putting this into handles
that correctly. I don't use `twm`, but chances are it will do exactly
as expected, therefore work correctly as soon as you put in the quotes.
All of which is completely off-topic to this list, of course.
>Bela<