nathancolgate / s3-swf-upload-plugin

A rails 3 gem which allow user upload files to S3 through an embedded flash directly. All UI has been moved out of flex and can be controlled by CSS and JavaScript callbacks.
http://www.nathancolgate.com
MIT License
317 stars 74 forks source link

Allow swf to load from cloudfront / another domain? #79

Closed wildebeast closed 10 years ago

wildebeast commented 12 years ago

I'm a huge fan of this plugin, but I'd like to be able to load the swf from another domain. How big of a change would it require to do so?

nathancolgate commented 12 years ago

Do you have crossdomain.xml files on all servers?

Other options: A little bit of searching turned up a few good potential resources:

http://stackoverflow.com/questions/3183911/cannot-load-swf-from-another-domain http://www.longtailvideo.com/support/forums/jw-player/setup-issues-and-embedding/5249/linking-to-playerswf-from-another-domain http://snipplr.com/view/30309/

Tried any of those options?

wildebeast commented 12 years ago

Sorry, I think the issue isn't actually loading the swf from offsite, but having it execute properly when it's loaded from elsewhere. I was experiencing issue #77 (browse button not showing up / swf not working even though it was on the page) when loading from another domain, but resolved this issue when I loaded these files from my domain.

nzifnab commented 12 years ago

I don't think it's the swf loading from another domain that's the issue. It's because of the images for the button being loaded from elsewhere. The actionscript code needs to use the crossdomain policy file if it's available to load those files.

SubaruWRX55 commented 11 years ago

i used the cross domain file but the flash doesn't seem to be loading. here is my setup

http://main_domain_with_upload_page/crossdomain.xml http://outside_domain/crossdomain.xml
http://outside_domain/flash/s3_upload.swf

(crossdomain.xml file in this github /lib/s3_swf_upload/railties/tasks/crossdomain.xml) flash file is loaded but it's not enabled.

do you have a working example?

nathancolgate commented 10 years ago

This has come up a couple of times. Folks have recommended hosting the image files locally.