POST Content-Length of 167289889 bytes exceeds the limit of 41943040 bytes

Viewed 1217

I get this message when I upload the pdf file and I changed the following values in php .ini

post_max_size=5000M

upload_max_filesize=1000M

max_file_uploads=1000M

and In the php file:

ini_set('upload_max_filesize', '600M');
ini_set('post_max_size', '600M');
header("Content-length: 167289889");

But I still get this error:

POST Content-Length of 167289889 bytes exceeds the limit of 41943040 bytes

php v : 7.4.11

1 Answers

you should also check in your apache configuration, in httpd.conf or apache.conf, or some other *.conf files you might be using for the following attribute

LimitRequestBody

usually it is set to 0 which is unlimited but on your server it might have a limit of its own

Related