error uploading a script

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • monomaniac21

    #1

    error uploading a script

    Hi all when using a very simple upload script that I know has worked in
    the past i get this errror on a server:

    Warning: move_uploaded_f ile(/home/folder/public_html/image/advert.jpg):
    failed to open stream: Permission denied in
    /home/folder/public_html/admin/edit.php on line 68

    Warning: move_uploaded_f ile(): Unable to move '/tmp/phpNzNVd5' to
    '/home/folder/public_html/image/advert.jpg' in
    /home/pronta/public_html/admin/edit.php on line 68

    Here is the function:

    move_uploaded_f ile($file_uploa d_tmpname,
    "/home/folder/public_html/image/$file_upload_fi lename");

    Any ideas on what might cause this?

  • Henrik Hansen

    #2
    Re: error uploading a script

    "monomaniac 21" <mcyi2mr3@googl email.com> writes:
    [color=blue]
    > Hi all when using a very simple upload script that I know has worked in
    > the past i get this errror on a server:
    >
    > Warning: move_uploaded_f ile(/home/folder/public_html/image/advert.jpg):
    > failed to open stream: Permission denied in
    > /home/folder/public_html/admin/edit.php on line 68
    >
    > Warning: move_uploaded_f ile(): Unable to move '/tmp/phpNzNVd5' to
    > '/home/folder/public_html/image/advert.jpg' in
    > /home/pronta/public_html/admin/edit.php on line 68
    >
    > Here is the function:
    >
    > move_uploaded_f ile($file_uploa d_tmpname,
    > "/home/folder/public_html/image/$file_upload_fi lename");
    >
    > Any ideas on what might cause this?[/color]

    Read the error?

    failed to open stream: Permission denied in
    /home/folder/public_html/admin/edit.php on line 68

    Do the webserver have access to the directory you are putting the file?


    --
    Henrik Hansen

    Comment

    Working...