Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't write local files in Flash Player 10+ online (but works when used locally)

I am trying to write a local file with Flash Player 10+ using the FileReference class, following the format from this blog post by Mike Chambers: http://www.mikechambers.com/blog/2008/08/20/reading-and-writing-local-files-in-flash-player-10/

Essentially the code is this:

private function onSaveButtonClick(event:MouseEvent):void{      
    fr = new FileReference();
    fr.save(fileToSave);}

It works fine locally on my machine but when used online, it doesn't bring up the save file dialogue when the save button is clicked. I assume this is some sort of permissions or security related issue?

like image 564
Steven Avatar asked Feb 01 '12 19:02

Steven


1 Answers

You should check your log for SecurityErrors. A sandbox violation is nearly always the cause when IO works locally but not online.

like image 143
Peter Hall Avatar answered Nov 07 '22 09:11

Peter Hall