PHP Warning: move_uploaded_file() unable to move

前端 未结 3 1604
时光取名叫无心
时光取名叫无心 2020-11-28 12:58

I\'ve been slowly learning PHP and have found an array of information on the subject and solutions posted by other developers. I am attempting to have an android application

相关标签:
3条回答
  • 2020-11-28 13:13

    This solved the problem for me:

    $ sudo chown -R www-data:www-data /var/www/html/
    
    0 讨论(0)
  • 2020-11-28 13:35

    This one worked well in Ubuntu Operating system. You only need to change the ownership

    sudo chown -R www-data:www-data (path to the image folder)

    0 讨论(0)
  • 2020-11-28 13:37

    Change upload permissions for /var/www/media2net/uploads/ either by changing owner with "chown" or by "chmod"

    Examples

    $ sudo chown apache:apache /var/www/media2net/uploads/
    $ sudo chmod 755 /var/www/media2net/uploads/
    

    Also, if downloaded_file.png already exists in that directory and it's owned by another user, then you would need to change ownership on that file as well.

    $ sudo chown apache:apache /var/www/media2net/uploads/downloaded_file.png
    

    This way, it can be successfully overwritten by Apache.

    0 讨论(0)
提交回复
热议问题