PHP: move_uploaded_file(): Unable to move '/

后端 未结 5 2109
伪装坚强ぢ
伪装坚强ぢ 2021-02-05 11:14

I keep getting this error on a new server I just setup

[Wed Feb 16 22:46:51 2011] [error] [client 71.1.236.114] PHP Warn         


        
5条回答
  •  伪装坚强ぢ
    2021-02-05 11:30

    Log into your ftp and confirm the following:

    • The folder exists, check for spellings
    • Check the properties of the folder and make sure the permissions have read+write 0666
    • Make sure the file is within your public html root, otherwise double check the owner of the file, and make sure PHP Has read / write access to it.

    looking at the log:

    Unable to move '/tmp/php6wlOg1' to    'upload/110216104651_00134_smooth_1440x900.jpg' 
    

    It seems to me that its looking in your root directory as upload/110216.... should be path.to/public_html/upload/110216....

    If none of the above work, please post your line of code that has move_uploaded_file on.

提交回复
热议问题