There are too many method for embedding flash in html, which way is the best? Requirements are:
I have been reading about SWFobject, has anyone used it/tested?
Navigate to the website you want to enable Flash on. next to the website's address in the address bar to bring up the drop-down as shown and click on Allow Adobe Flash. Under Website Permissions, ensure the slider for Adobe Flash is moved to the On position as shown.
To insert flash into your HTML files you must use the HTML tag object, which is used to place multimedia items like music, movies, and now Flash files onto web pages. We will assume that the name of your flash file is "example. swf" for this lesson, but you should rename it to the actual name of your flash file.
Flash animations should be embedded using both "<object>" and "<embed>"
Flash is a vector animation software that was created with the intention of creating animations for web pages. Because vector graphics are so light, they are perfect for the web. There are different ways to insert a Flash file in HTML.
To create a SWF file in Photoshop, first open the Photoshop application and create a new document. Next, go to File > Export > Export Movie. In the Export Movie dialog box, select the format you want to export the file as (in this case, SWF) and click Export. Finally, give the file a name and click Save.
In a project I work on we use SWFobject which works like a charm, it allows you to check for a specific version and also display alternative content if flash is not supported.
var fn = function() {
if(swfobject.hasFlashPlayerVersion("9.0.115"))
{
var att = { data:"flash.swf", width:"y", height:"x" };
var par = { menu: "false", flashvars: "" };
signUp = swfobject.createSWF(att, par);
}
}
swfobject.addDomLoadEvent(fn);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With