Jump to content


Photo

PHP Coding Error / Problem


  • Please log in to reply
1 reply to this topic

#1 matthew01

matthew01
  • New Members
  • Pip
  • Newbie
  • 1 posts

Posted 11 June 2006 - 02:10 AM

Hi Guys,

I have got this upload image script, But it has an error, I have Chmoded the folder to 777, The folder I have chmoded to 777 is "companylogos"

Here is the errors I get

Warning: move_uploaded_file(\directory\stores\images\companylogos\ae4a9edc1338bbf4fc12cbb 4dc6f5f2c.gif): failed to open stream: Permission denied in /var/www/vhosts/matthewscomputerguide.com/httpdocs/directory/CMSAdmin/StoreManagement_DD.php on line 219

Warning: move_uploaded_file(): Unable to move '/tmp/phpd679qA' to '\directory\stores\images\companylogos\ae4a9edc1338bbf4fc12cbb4dc6f5f2c.gif' in /var/www/vhosts/matthewscomputerguide.com/httpdocs/directory/CMSAdmin/StoreManagement_DD.php on line 219


Warning: rename(): open_basedir restriction in effect. File(/directory/stores/images/companylogos/ae4a9edc1338bbf4fc12cbb4dc6f5f2c.gif) is not within the allowed path(s): (/var/www/vhosts/matthewscomputerguide.com/httpdocs:/tmp) in /var/www/vhosts/matthewscomputerguide.com/httpdocs/directory/CMSAdmin/StoreManagement_DD.php on line 64

Warning: Cannot modify header information - headers already sent by (output started at /var/www/vhosts/matthewscomputerguide.com/httpdocs/directory/CMSAdmin/StoreManagement_DD.php:219) in /var/www/vhosts/matthewscomputerguide.com/httpdocs/directory/CMSAdmin/StoreManagement_DD.php on line 74

Matthew

I now know its path problem as I can't use the absolute paths. I have tried a few different paths but they seem to not work.

Could some one give me a hand. Thanks

Matthew

#2 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 11 June 2006 - 10:26 AM

By looks of things the folder that you are moving the uploaded file to doesnt have the correct permissions set, that is you are retrieving that error




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users