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

Re: emacs-w3m encodes CGI query stringsimproperly!



clemens fischer <ino-qc@spotteswoode.de.eu.org>:

> i've got a wiki running here, and when saving an edited page, the URL
> submitted looks like
>
>   http://127.0.0.1:8882/cgi/awki.cgi?save=true&amp;page=ClemensFischer
>
> this URI should have been:
>
>   http://127.0.0.1:8882/cgi/awki.cgi?save=true&page=ClemensFischer
>
> (note `&' instead of `&amp;')  note that this is a wiki edit POSTing
> simple text, not HTML markup.

i think it's clearer to look at the log:

0 p1 # tai thttpd |g 'post '
127.0.0.1 - - [01/Jun/2003:11:42:08 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&amp;page=FunnyRemarks HTTP/1.0" 200 50000 "http://127.0.0.1:8881/cgi/awki.cgi?edit=true&page=FunnyRemarks"; "Emacs-w3m/1.3.4rc2 "
127.0.0.1 - - [01/Jun/2003:12:15:07 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&amp;page=FrontPage HTTP/1.0" 200 50000 "http://127.0.0.1:8881/cgi/awki.cgi?edit=true&page=FrontPage"; "Emacs-w3m/1.3.4rc2 "
127.0.0.1 - - [01/Jun/2003:12:26:15 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&page=FrontPage HTTP/1.1" 200 50000 "http://127.0.0.1:8881/cgi/awki.cgi?save=true&page=FrontPage"; "ELinks (0.4.2; FreeBSD 4.8-STABLE i386; 123x52)"
127.0.0.1 - - [01/Jun/2003:12:26:21 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&page=FrontPage HTTP/1.1" 200 50000 "http://127.0.0.1:8881/cgi/awki.cgi?save=true&page=FrontPage"; "ELinks (0.4.2; FreeBSD 4.8-STABLE i386; 123x52)"
127.0.0.1 - - [01/Jun/2003:13:50:29 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&page=CategoryCategory HTTP/1.1" 200 50000 "http://127.0.0.1:8881/cgi/awki.cgi?save=true&page=CategoryCategory"; "ELinks (0.4.2; FreeBSD 4.8-STABLE i386; 123x52)"
127.0.0.1 - - [01/Jun/2003:13:50:46 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&page=CategoryCategory HTTP/1.1" 200 50000 "http://127.0.0.1:8881/cgi/awki.cgi?save=true&page=CategoryCategory"; "ELinks (0.4.2; FreeBSD 4.8-STABLE i386; 123x52)"

you can see that the current release candidate #2 sends
...?save=true&amp;page=... whereas elinks sends
"...?save=true&page=...".  emacs-w3m rc2 does this only on POST
requests as far as i know, get requests are sent properly, example:

127.0.0.1 - - [01/Jun/2003:11:39:36 +0200] "GET /127.0.0.1/cgi/awki.cgi?edit=true&page=FunnyRemarks HTTP/1.0" 200 50000 "ht
tp://127.0.0.1:8881/cgi/awki.cgi" "Emacs-w3m/1.3.4rc2 "
127.0.0.1 - - [01/Jun/2003:11:42:08 +0200] "POST /127.0.0.1/cgi/awki.cgi?save=true&amp;page=FunnyRemarks HTTP/1.0" 200 5000

regards,

  clemens