The default phpmyadmin upload file size is 2M. If you want phpmyadmin to upload large files exceeding 2M, you need to modify the size configuration of the phpmyadmin upload file or upload the large file in several batches. It is said that it is much more convenient to modify the upload file size limit of phpmyadmin.
Solving the problem of phpmyadmin upload file size limit involves modifying the php.ini configuration file and phpmyadmin configuration file.
Step 1: Modify the file upload size configuration in the php.ini configuration file
This step is consistent with the general PHP.INI configuration file upload function method and needs to be modified There are two option values in the php.ini configuration file, upload_max_filesize and post_max_size. (I have tested it myself, assuming it is only 50M, just set it here)
Step 2: Modify the php execution time and memory limit to implement the large file upload function of phpmyadmin
If you want phpmyadmin to upload large files, you also need to modify the max_execution_time (maximum execution time of the php page), max_input_time (the maximum time for the php page to accept data), and memory_limit (the maximum memory occupied by the php page) in the php.ini configuration file. configuration options.
This is because when phpmyadmin uploads large files, the execution time and memory usage of the PHP page will inevitably become longer and larger. This requires the cooperation of the PHP operating environment. Simply modifying the upload file size limit is not enough.
Step 3: Modify the phpmyadmin configuration file
After completing the relevant configuration of php.ini, you also need to modify the phpmyadmin configuration.
1. Modify the $cfg['ExecTimeLimit'] configuration option in the phpmyadmin config configuration file. The default value is 300 and needs to be modified to 0, which means there is no time limit.
2. Modify $memory_limit in the import page in the root directory of the phpmyadmin installation.
PHP Chinese website has a large number of free phpmyadmin introductory tutorials, everyone is welcome to learn!
The above is the detailed content of How to modify phpmyadmin restrictions. For more information, please follow other related articles on the PHP Chinese website!