How to set the file size in php: First use the linux command to find the file, the code is [find / -name php.ini]; then set the file size, the code is [client_max_body_size 35m].
How to set the file size in php:
Modify the php.ini file upload_max_filesize = 100M
andpost_max_size = 100M
, then the question is, how do I know where this file is?
1. Linux file search command:
find / -name php.ini
2. However, it is too troublesome to modify through shell. It is much more convenient to download it locally using xftp, modify and then replace.
After modifying and replacing, modify another part:
3. Below is a screenshot of the article. I modified it to 100M. You can adjust the size according to your own needs. It would be nice if you know where to modify it.
Related learning recommendations: PHP programming from entry to proficiency
The above is the detailed content of How to set file size in php?. For more information, please follow other related articles on the PHP Chinese website!