I use ajax to upload files to Php. all files within the range of Php file size can be obtained, however, if the file I uploaded is mb, php won't get anything. print the returned information as follows: array (0) {} NoProperties does not use php, browsers, and other modifications... I use ajax to upload files to Php. all files within the range of Php file size can be obtained, however, if the file I uploaded is a M file, php won't get anything. print the returned information as follows:
Array (0 ){}
No Properties
Without modifying the size of configuration files such as php and browsers, how can I obtain the file information or determine the file size? This is because the file cannot be obtained, let alone the file size. please give me some advice!
Reply content:
I use ajax to upload files to Php. all files within the range of Php file size can be obtained, however, if the file I uploaded is a M file, php won't get anything. print the returned information as follows:
Array (0 ){}
No Properties
Without modifying the size of configuration files such as php and browsers, how can I obtain the file information or determine the file size? This is because the file cannot be obtained, let alone the file size. please give me some advice!
It seems that you can use js to check the file size
var file = document.getElementById(InputElementID);var sieze = dom.files[0].size;
Has the size limit of files uploaded by webserver and php. ini been changed?
It should be that php has enough running time, but the file is not uploaded successfully, so there is no file information at all.
I passed a hidden value in the past. if it is obtained, it indicates that the data in the Post object is consistent with the size. Otherwise, it will be blocked. Theoretically, this is acceptable, but it is not the best solution. You are welcome to answer this question, the problem here is that some POST software can directly POST the file stream data. this is very embarrassing.