开发者

How do I download flash files embedded using SWFObject

开发者 https://www.devze.com 2022-12-08 19:22 出处:网络
A site I use displays a flash file, which is embedded dynamically using SWFObject. I want to download the flash file locally, so I can run it when I don\'t have access to the net. However, when I try

A site I use displays a flash file, which is embedded dynamically using SWFObject. I want to download the flash file locally, so I can run it when I don't have access to the net. However, when I try to open t开发者_运维问答he url to the swf file, it demands an 'id' parameter that is normally passed by the SWFObject Javascript.

Specifically, the source of the page contains:

swfobject.embedSWF("/bin/loader.swf", "main", "100%", "100%", "9", false, flashvars, params, attributes);

And the flashvars have the following definiton:

var flashvars = {
        file_id: "imilc2lxnfft",
        app: "main-502.swf",
        show_play_button: "false",
        autoplay: ""

When I try to access site.com/bin/loader.swf, it says it requires a file_id parameter.

How do I pass the parameter and download the file to my desktop?


Save locally (with a D/L manager):

http://example.com/bin/loader.swf
http://example.com/main-502.swf

And create a local HTML file with the SWFObject JS code, including the flashvars and a <div> in your page with the right id (id="name" in this case).

It's also possible you don't need the loader, and the 2nd swf file will work standalone.


You'll need to create a webpage to house the SWF you've downloaded that passes the same flashvars to it as the webpage you're getting it from. I'd use Firefox's right-click "save web page" function; choose to save 'Web page, complete'. This will save the page and all its support files somewhere. Then you should be able to edit that page down just to display the embedded SWF applet, and pass the necessary flashvars to it.


Have you tried looking at the page source and search for instances of .mp4? Might prove helpful.


I guess the loader.swf is a preloader that loads the original movie based on the file_id parameter.

0

精彩评论

暂无评论...
验证码 换一张
取 消