Flash 8 ExternalInterface Crash Bug
This is one of those things that you can stay up until 1 AM trying unsuccessfully to debug, and then the next morning you spot the trouble immediately.
If a swf uses ExternalInterface to call a JavaScript function that removes the swf from the document, the browser will crash. PC Firefox gives the dubiously helpful error "The plugin performed an illegal operation. You are strongly advised to restart Firefox."
Simply delay the removing call using setTimout, and all is well.
If a swf uses ExternalInterface to call a JavaScript function that removes the swf from the document, the browser will crash. PC Firefox gives the dubiously helpful error "The plugin performed an illegal operation. You are strongly advised to restart Firefox."
Simply delay the removing call using setTimout, and all is well.
6 Comments:
I ran into this with sIFR, too. See the test page at http://tests.novemberborn.net/browsers/safari/fscommand-redraw/
I've already reported this to the Safari and Firefox developers, and appearantly it is fixed with Flash 9 (it was a bug in Flash).
Nice post, saved me lots of time and angry gesticulations - Thanks a lot.
I read somewhere that the Flash 8 ExternalInterface code is sloppy as hell.
Sweet! That just saved me hours worth of crazy hacked-up workarounds. Thanks!
I experienced a similar thing, although with Flash 9.
My swf was calling javascript that hides itself however this code also calls a user defined callback function just after hiding. If this callback function did nothing, or did something quick, everything was ok. If it showed an alert box then when returning from the callback function firefox would crash.
setTimeout didn't help, but running the callback before hiding the swf did.
Very very helpful, I`ve just encountered this problem too, and it drove me mad because Firefox just crashed without any error. It didn`t wrote something useful in the eventlog, just nothing!
IE 7 and Opera 9 don`t seem to be affected by this bug.
I would've spent hours trying to fix it before commiting suicide, Thanks a lot !! : D
Post a Comment
<< Home