Answer the question
In order to leave comments, you need to log in
How to change the file size limit?
Hello. I have an application that complains that the file size is too large. Tried using express urlencoded and specifying 500*1024*1024 there, didn't work. I installed body-parser and tried again, similar and strange behavior here. Please tell me how can I fix this?
app.use(bodyParser.json({ limit: 500*1024*1024, extended: true }));
app.use(bodyParser.urlencoded({ limit: 500*1024*1024, extended: true }));
Answer the question
In order to leave comments, you need to log in
Guys, firstly, it is correct to use one of the options:
app.use(bodyParser({ limit: 500*1024*1024, extended: true })); // или 1 (можно указать '500mb') например
app.use(bodyParser.json({ limit: 500*1024*1024, extended: true })); // или 2
app.use(bodyParser.urlencoded({ limit: 500*1024*1024, extended: true })); // или 3
client_max_body_size 5M;
/etc/nginx/nginx.conf
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question