Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

application/x-www-form-urlencoded

7 views
Skip to first unread message

runeof...@gmail.com

unread,
Oct 14, 2014, 10:02:33 AM10/14/14
to
Er det normalt at en browser sætter en content-type lig med

application/x-www-form-urlencoded

ved en GET request? Altså hvis en browser HENTER en side? Jeg har ikke set det før.


MVH
Rune Jensen

Jens Peter Karlsen

unread,
Oct 14, 2014, 11:54:44 AM10/14/14
to
Bruges normalt kun med en POST.

On Tue, 14 Oct 2014 07:02:33 -0700 (PDT), runeof...@gmail.com
wrote:

>application/x-www-form-urlencoded
>
>ved en GET request? Alts� hvis en browser HENTER en side? Jeg har ikke set det f�r.

runeof...@gmail.com

unread,
Oct 14, 2014, 4:15:09 PM10/14/14
to
Den tirsdag den 14. oktober 2014 17.54.44 UTC+2 skrev Jens Peter Karlsen:

> Bruges normalt kun med en POST.

Så vidt jeg forstår, så skal den sættes ved brug af AJAX (XMLHTTPObject).

Også ved GET.

Korrekt forstået?


MVH
Rune Jensen

Benny

unread,
Oct 14, 2014, 4:47:16 PM10/14/14
to
runeof...@gmail.com wrote:
> Er det normalt at en browser s�tter en content-type lig med
>
> application/x-www-form-urlencoded
>
> ved en GET request? Alts� hvis en browser HENTER en side? Jeg har ikke set det f�r.
>
>
> MVH
> Rune Jensen
Det er vel html'en og ikke browseren der bestemmer. Get og urlencoded
lyder til v�re f�tre - '&' separatet list af key=value items postfixed
en url
Fra html 4.01 - 17.13.3 Processing form data

"
If the method is "get" and the action is an HTTP URI, the user agent
takes the value of action, appends a `?' to it, then appends the form
data set, encoded using the "application/x-www-form-urlencoded" content
type. The user agent then traverses the link to this URI. In this
scenario, form data are restricted to ASCII codes.
If the method is "post" and the action is an HTTP URI, the user agent
conducts an HTTP "post" transaction using the value of the action
attribute and a message created according to the content type specified
by the enctype attribute
"

Konceptionelt set, n�r enctype kun v�re en af disse:
* multipart/form-data
* application/x-www-form-urlencoded

bestemmer den vel ikke om det er GET eller POST, men om den n�dvendigvis
m� v�re POST (bin�r data indeholder garanteret ikke key/value pairs)

Mvh
0 new messages