6 Replies Latest reply on Aug 5, 2007 3:47 PM by ticktak

    Problems with FileUpload

      I am uploading files to a server using the FileReference Class. I works well on my localhost. When I go online it fails with Opera, Safari and Firefox on mac. On a Windows PC it only works with Internet Explorer.

      Has anyone else experienced this? I read several posts online with similar issues, but no way to work this around.

      Why is this happening? Is this a bug? or an issue of my server?

      Thanks for your insights
        • 1. Re: Problems with FileUpload
          ticktak Level 1
          BTW, in every browser where it fails the error I get is this:


          Error #2038: File I/O Error.
          • 2. Re: Problems with FileUpload
            kglad Adobe Community Professional & MVP
            check your file name. online, case counts: yourfile.xxx is not the same as yourFile.xxx
            • 3. Re: Problems with FileUpload
              ticktak Level 1
              Thanks kglad,
              I fear the problem is more than that though. I just tried exactly the same files on a different server and they worked on both Safari, and Firefox on a Mac.

              The example I'm trying is very simple: a single file is selected and then transfered to a folder. There's no file manipulation or whatsoever.

              I read in other forums of users reporting problems with Firefox on macs while uploading files. Others didn't notice that problem. It makes me think it is a problem related to the server and the headers Flash sends.

              I noticed for instance that when uploading an image file, flash sends this:

              type = application/octet-stream

              as opposed to:

              type = image/jpg, which prevents some image processing scripts from dealing with the file.

              I've spent many days dealing with this and it's already a very frustrating thing. Not to belittle flash, but a simple file upload through an html form takes 2 seconds, and it's 100% warranted to work. Things as simple as this should not be such an endeavor. We are not sure what to do now about this project.
              • 4. Re: Problems with FileUpload
                kglad Adobe Community Professional & MVP
                post your code using the attach code option.
                • 5. Re: Problems with FileUpload
                  ticktak Level 1
                  Thanks for taking a look at this code.
                  As I mentioned it earlier I have mix results with it:
                  It works here:
                  -My localhost testing from within flash, and from safari, and firefox.
                  -Server A (a friend's): from any windows PC and Mac browser
                  -Server B (where it should be finally hosted): Only works from windows PC browsers. Whenever I tried from a mac browser I get this error:
                  Error #2038: File I/O Error. URL: url of php script.

                  Earlier I made the php script that I'm addressing print a confirmation variable whenever it is called. In the situations the upload fails it seems that flash cannot even address it (!) since the script doesn't even print that variable.
                  So here's the code:

                  • 6. Re: Problems with FileUpload
                    ticktak Level 1
                    In case this is of any use:
                    these are the headers from the server where it fails and the server where it succeeds:

                    UNSUCCESSFUL ATTEMPT: