hi

when i want to upload an attachment with squirrelmail I get this errror: Could not move/copy file. File not attached
everything else works perfectly. I use squirrelmail + cyrus + postfix with mandrake 9.1.
i configured squirrelmail to use /var/spool/squirrelmail as the attachment directory and changed the permissions to 770 user=apache group=apache.
in the php.ini I have: file_uploads=on and the stuff with the memory and filesizes is also correct.
I also activated display_errors=on and it showed me this:
Warning: File upload error - unable to create a temporary file in Unknown on line 0
Notice: Undefined index: attachfile in /usr/share/squirrelmail/src/compose.php on line 1246
what is wrong?

thx in advance

    5 days later

    I imagine the 2nd message causes the 1st. UTSL!! Look up line 1246 in compose.php, and see if you can figure out why it doesn't know where to put the arrachment. 🙂

      I would think the notice (not error) for undefined index is a result of squirrel mail not being set to generate a proper error message based on a successful file upload. It's expecting the upload to go through and the variable to be set as a result.

      This, to me, seems like the file isn't being uploaded at all. Restrictive settings on /tmp or incorrectly defined tmp dir for php may be to blame here. Try uploading a file via a small custom upload module and see if you can copy that to another location. Or; simply echo uploaded file properties before unlinking.... just to make sure this is a squirrel mail prob.

      p.s: What version of squirrel mail is this?

      -m.

        Hi I'm using squirrelmail 1.4
        but i finally solved the problem. the entry upload_dir was commented out in my php.ini. after uncommenting it, everything worked fine.
        anyway, thx for the help

          Write a Reply...