[Fwd: php3 question...]

Eric Samson airickjay@home.com
Fri, 17 Mar 2000 07:18:09 -0700


Ok, I am totally new at this, and learning as I go....

I am trying to upload files through a form, and trying to put them into
a temporary directory to transfer them to a permanent file...  I have
the Wrox php book, and I am totally lost at this point... I guess there
is a default temp directory where this stuff is put, but I have no clue
how to determine where that is...  Can anyone help?  Thanks in advace
all....

This is what I coded:

if ($file1) {
     if (copy($file1,"/temp/$lname")) {
      echo ("<B>Photo 1 received:  thank you!</B>");
     } else {
      echo ("<B>Error saving photo 1. </B>" . "However, your information
will still be processed.");
     }
    }

    if ($file2) {
     if (copy($file2,"/temp/$lname")) {
      echo ("<B>Photo 2 received:  thank you!</B>");
     } else {
      echo ("<B>Error saving photo 2. </B>" . "However, your information
will still be processed.");

This is the warning:

Warning: Unable to open 'none' for reading: No such file or directory in
/usr/local/apache/htdocs/php/adinfo_action.php3 on line 232
Error saving photo 1. However, your information will still be processed.

Warning: Unable to open 'none' for reading: No such file or directory in
/usr/local/apache/htdocs/php/adinfo_action.php3 on line 240
Error saving photo 2. However, your information will still be processed.

I think there is a directory I should be pointing at, but I will be
darned if I kno where it is....