Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to embed a flash object on my website?

Tags:

html

flash

embed

Well, I must say this is embarrassing to ask, but to my defense I'll say that throughout my years of web development I've never encountered a case where embedding flash was absolutely necessary.

The Question

  • Simple, how do I embed a flash object of any kind (*.swf or if there any other options, them too) to my website?

Some Points

  • I don't need the code, I already have that, I just don't really understand it.
  • I'm looking for a good explanation on how to use the <embed> or <object> elements.
  • I've been searching around but couldn't find a clear explanation, even in the specs.

I'd award any good answer with an upvote, a cookie, and an accepted answer to the best :)

like image 653
Madara's Ghost Avatar asked Sep 24 '11 09:09

Madara's Ghost


People also ask

How do you embed a Flash in a web page?

Choose File > Publish. Flash will now create the <object>, <param>, and <embed> tags for you. It will also create the classid and pluginspage attributes. Open the HTML document that Flash created, view the HTML source and copy the code into your HTML page where you want your Flash movie.

How add SWF to HTML?

You can embed SWF content in HTML content within an AIR application just as you would in a browser. Embed the SWF content using an object tag, an embed tag, or both. Note: A common web development practice is to use both an object tag and an embed tag to display SWF content in an HTML page.


2 Answers

Definitions:

http://www.w3.org/wiki/HTML/Elements/embed

http://www.w3.org/wiki/HTML/Elements/object

Explanation on how to embed a flash object from Adobe:

http://kb2.adobe.com/cps/415/tn_4150.html

"The HTML OBJECT tag directs the browser to load Adobe Flash Player and then use it to play your SWF file."

like image 56
magritte Avatar answered Oct 23 '22 08:10

magritte


Change "YOURFILENAMEHERE.swf" with your .swf file name.

<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" WIDTH="320" HEIGHT="240" id="Yourfilename" ALIGN="">
<PARAM NAME=movie VALUE="YOURFILENAMEHERE.swf">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=bgcolor VALUE=#333399>
<EMBED src="Yourfilename.swf" quality=high bgcolor=#333399 WIDTH="320" HEIGHT="240" NAME="Yourfilename" ALIGN="" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED></OBJECT> 
like image 44
Faruk KAHRAMAN Avatar answered Oct 23 '22 07:10

Faruk KAHRAMAN