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

Re: Search engine duckduckgo URL results 404

Katsumi Yamaoka <yamaoka@xxxxxxx> writes:

> Hi,
> I tried: C-u M-x w3m-search RET duckduckgo RET emacs-w3m RET
> It doesn't work; only the duckduckgo-lite top (query box) page
> appears with no search string.  I didn't modify
> `w3m-search-engine-alist' so the duckduckgo entry is:
> ("duckduckgo" "https://duckduckgo.com/lite" utf-8 "q=%s")
> Does it mean that emacs-w3m fails to send a search string as
> post-data?  However
> In [emacs-w3m:13634]
> On Wed, 01 Jul 2020 22:29:05 +0200, Tomas Nordin wrote:
>> I have this entry in w3m-search-engine-alist:
>> '("duck" "https://duckduckgo.com/lite/?q=%s")
>> and that has been working fine for years. But now
> It works for me.

Interesting. And even more interesting because now it works for me too
again, the same way as before my report. This must have been something
about how duckduckgo produced the resulting links?

But a little confusing still for me is how the resulting links are
produced. In w3m I get links like this using the search term
"w3m and duckduckgo as search engine"


(copied with `w3m-print-this-url')

Using firefox, going to https://lite.duckduckgo.com/lite/ using the
search bar with the same search term as above, the corresponding link
seem to be


(copied with right click and "copy link location")

which is free from the redirection step if that is the right term to
use. Also, after visiting one of the results in w3m and going back in
history, I have to go back two times (to also pass the redirection).

I wonder if there is a smart way to write the alist entry to escape this
redirection kind of links. Maybe one should consult duckduckgo about
that. There is something about the URL meanings here[1] but I didn't find
anything relevant.

[1] https://duckduckgo.com/params