In this Quick Tip screencast, I'll show you how to embed your Flash SWFs in an HTML webpage using SWFObject.
Where to Get SWFObject
The latest version of SWFObject is available on its Google Code page. Grab whichever file is marked as "Featured" on this page (at time of writing, that's version 2.2).
Watch the Screencast
The Starting HTML
For a beginner's guide to HTML, see this tutorial.
<!DOCTYPE html> <html> <head> <title></title> </head> <body></body> </html>
The Final HTML
<!DOCTYPE html> <html> <head> <title>Our HTML Page</title> <script type="text/javascript" src="swfobject.js"></script> <script type="text/javascript">swfobject.embedSWF('animation.swf', 'flash', '550', '400', '9.0.0');</script> </head> <body> <div id="flash"> <p>At this moment you do not support Flash Player 9. We're sorry.</p> </div> </body> </html>
Thank You
Thank you for watching, if you have any questions, feel free to comment.
Comments