how i can read files from a multipart request? #2734
-
SummaryHi friends, i'm trying read a file and the content inside then from a multipart form and i'm stuck, dont know how to proceed. axum version0.7.5 |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hi Miguel~ Here's a demo code in this blog: https://blog.hiibolt.com/rust/axum/tokio/server/2024/01/10/MultipartRustServer.html#result You can follow it to get the file |
Beta Was this translation helpful? Give feedback.
-
i solved my error. what is relationated with the file size. |
Beta Was this translation helpful? Give feedback.
Hi Miguel~
Here's a demo code in this blog: https://blog.hiibolt.com/rust/axum/tokio/server/2024/01/10/MultipartRustServer.html#result
You can follow it to get the file
data
(bytes) and filename
.The blog shows that the file is in a multipart form data and named with
fileupload
.