From 35ff499b9237c1c7588ff2799f2a524d3223b0b7 Mon Sep 17 00:00:00 2001 From: zhangbao Date: Sun, 29 Mar 2020 10:23:34 +0800 Subject: [PATCH] fix typo --- 5-network/02-formdata/article.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/5-network/02-formdata/article.md b/5-network/02-formdata/article.md index 1c28296d..d281d075 100644 --- a/5-network/02-formdata/article.md +++ b/5-network/02-formdata/article.md @@ -12,7 +12,7 @@ let formData = new FormData([form]); If HTML `form` element is provided, it automatically captures its fields. -The special thing about `FormData` is that network methods, such as `fetch`, can accept a `FormData` object as a body. It's encoded and sent out with `Content-Type: form/multipart`. +The special thing about `FormData` is that network methods, such as `fetch`, can accept a `FormData` object as a body. It's encoded and sent out with `Content-Type: multipart/form-data`. From the server point of view, that looks like a usual form submission. @@ -81,7 +81,7 @@ for(let [name, value] of formData) { ## Sending a form with a file -The form is always sent as `Content-Type: form/multipart`, this encoding allows to send files. So, `` fields are sent also, similar to a usual form submission. +The form is always sent as `Content-Type: multipart/form-data`, this encoding allows to send files. So, `` fields are sent also, similar to a usual form submission. Here's an example with such form: