Where does PHP save temporary files during uploading?

前端 未结 8 1419
情书的邮戳
情书的邮戳 2021-02-07 05:50

I am using XAMPP on Windows. By printing $_FILES[\"file\"][\"tmp_name\"], it seems that the temporary file was saved at C:\\xampp\\tmp\\phpABCD.tmp. But I cannot se

8条回答
  •  终归单人心
    2021-02-07 06:16

    php stores all temporary files, that includes uploaded files, in the temporary files directory as specified in the php.ini. Note that for uploads, those files might be removed as soon as the script the file was uploaded to was terminated (so unless you delay that script, you probably won't see the uploaded file). Another reason might be that the file is simply hidden on the file system.

    So if you want to see the file, you might want to make sure you see all hidden files in the explorer and delay the script as long as you need to find the file.

提交回复
热议问题