From 3729281a1ebd8e3be5f7a3e008996070795b9a89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9?= Date: Wed, 22 Jan 2025 08:35:17 +0100 Subject: [PATCH] Doc BodyParser: Add multipart form info about the file data --- docs/api/ctx.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/api/ctx.md b/docs/api/ctx.md index fdb2adc010..d24eef2161 100644 --- a/docs/api/ctx.md +++ b/docs/api/ctx.md @@ -276,6 +276,12 @@ It is important to specify the correct struct tag based on the content type to b | `application/xml` | xml | | `text/xml` | xml | +:::note + +When handling `multipart/form-data`, only the form values can be directly assigned to the struct fields. Files included in the request are not automatically assigned to the struct. You must handle files separately using [`FormFile`](#FormFile) or other file-specific methods. + +::: + ```go title="Signature" func (c *Ctx) BodyParser(out interface{}) error ```