Home  >  Article  >  Backend Development  >  How to set file size in php?

How to set file size in php?

coldplay.xixi
coldplay.xixiOriginal
2020-07-10 16:59:033174browse

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 file size in php?

How to set the file size in php:

Modify the php.ini file upload_max_filesize = 100Mandpost_max_size = 100M, then the question is, how do I know where this file is?

1. Linux file search command:

find / -name php.ini

How to set file size in php?

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:

How to set file size in php?

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.

How to set file size in php?

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!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn