-
Flash MX getURL bug?
I have had a site up for some time, where a flash file has a getURL() action to .doc files, .pdf files, etc. I was compiling it as Flash 5 .swf for maximum compatibility.
Recently I added some features that required me to compile as Flash 6 player. Immediately the links to the .doc files and .pdf files and such stopped working.
I ended up having to have Flash call a javascript function to open the files. I'm sure this is some "security feature." Anyone else run into it and find a better way to get around it?
-
Retired SCORM Guru
"What really bugs me is that my mom had the audacity to call Flash Kit a bunch of 'inept jack-asses'." - sk8Krog
...and now I have tape all over my face.
-
The code is painfully simple.
When published as a Flash 5 .swf, this works:
getURL("Resources/Paper.doc","_blank");
It causes IE to prompt for a download, and everything's fine.
When published as a Flash 6 .swf, the same thing happens, but after you indicate whether you want to open or save the file (doesn't matter what you choose) IE says the file is unavailable.
I think when a non-displayable file is requested in IE, it downloads the file in user cache, and then accesses it locally either to open or save it. Somehow Flash short-circuits that process, the file never makes it to local cache, and then when IE goes looking for it it's not there.
So I had to do this:
getURL("javascript:openDoc('Resources/Paper.doc')");
And now it works fine again.
I was just wondering if there's some kind of security setting I can change, because it's silly to have to go around Flash just to link to downloadable files.
-
Senior Member
Is there any change in html location or if you now load the movie inside another?Any change that has with paths to do?
I ask this as links are relative to the html doc's location and not the swf file's? The javascript thing may change that.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|