upload file problem



I'm trying to upload the file. It's showing me successfully uploaded.
But it's not able to move from temp directory to my defined directory

my code:

if (is_uploaded_file($_FILES['myfile']['tmp_name'])) {
move_uploaded_file($_FILES['myfile']['tmp_name'], $myfilename);
echo "File ". $_FILES['myfile']['name'] ." uploaded successfully.\n";
} else {
echo "File uploading error";
}

Thanks in advance.

-Jignesh
.



Relevant Pages

  • Re: CSV file into an array
    ... It goes a a temp directory under a temp name. ... This is done by the code in the receiving script (= the script mentioned in ... First get the upload up and running, then start with the handling of the ... If you want to test your result somehow (the array), ...
    (comp.lang.php)
  • Re: Problem with large file upload
    ... I am writing a Perl/CGI script to upload files from a HTTP client. ... It saves the upload into a temporary file. ... Perhaps the server is not ... The default temp directory appears to be found as follows... ...
    (comp.infosystems.www.authoring.cgi)
  • Re: [PHP] upload file problem
    ... I'm trying to upload the file. ... It's showing me successfully uploaded. ... But it's not able to move from temp directory to my defined directory ... To unsubscribe, visit: http://www.php.net/unsub.php ...
    (php.general)
  • RE: [PHP] File Upload problem
    ... file, rename it or whatever, but it keeps returning "The document ... contains no data" and as far as I know the php script isn't even run. ... Moving the file is a requisite to the upload operation as PHP stores the ... upload in a temp directory and deletes it quickly once the upload is ...
    (php.general)
  • Re: [PHP] Cant upload file greater than 11kb
    ... It has been my experience that max_file_size does terminate the upload ... But you are right, if it gets to the upload, your stuck. ... > If i remembers the earlier messages you have said the php.ini settings ... >>temp directory then copied to the maps dir. ...
    (php.general)