views:

71

answers:

1

Hi,

I've created a fileUpload.mxml component in flex 3 which basically uploads m4a's to a designated server. The general code is below:

private var uploadURL:URLRequest;
private var file:FileReference;

file=new FileReference();
file.browse(getTypes());

var params:URLVariables = new URLVariables();
params.fileID = model.selectedFileUpload.fileUploadId.toString();
uploadURL.data = params;
uploadURL.url= model.mainDir + "/php/upload.php";

file.upload(uploadURL);

Everything works fine on a windows pc, but not on a mac pc. It stops at file.upload(uploadURL) (and thus doesn't trigger Event.COMPLETE).

Has anyone experienced this problem on the mac os x? And if so, how did you overcome it?

Any advice would be appreciate.

Regards, Angus

+1  A: 

The COMPLETE event is not triggered in Mac due to a bug UNLESS the server send ANY output back to the server.

A simple echo of any string would do.

this issue is detailed in the SWFUpload boards along this very solution (there may be other causes, also discussed in that thread, but the not output is the most common one): http://swfupload.org/forum/generaldiscussion/872

Johnco
Johnco, this fixes problem I was having. Thanks very much for your help.
Angus