PHP - empty $_POST and $_FILES - when uploading larger files

前端 未结 5 1576
深忆病人
深忆病人 2020-11-29 04:18

I have a following problem, I have HTML form that uploads a file with some extra information. But it allows to upload files that only less then 10MB. But when user tries to

5条回答
  •  栀梦
    栀梦 (楼主)
    2020-11-29 04:44

    There are some limits - both on client and server side.

    On client side, the MAX_FILE_SIZE field is not of much use, perhaps browser may take it as a hint; but rather browsers follow their configured limits.

    On server side, check php.ini for:

    upload_max_filesize = 5M
    
    post_max_size = 5M 
    
    max_input_time = ...
    

    Also check Apache's log for notes about dropped POST body or such.

提交回复
热议问题