Vectorials
Flash Perfection
3D Lessons
Tutorialkit
Markup Tutorials
Learn PHP
network
adv banner
HTML and CSS  Home HTML and CSS Tutorials Flash for Beginners - Embed a swf Source Code into an HTML
rss

Flash for Beginners - Embed a swf Source Code into an HTML

Author: CambodiaXP.com More by this author


It's been a while I didn't write the flash for beginners tips serie, but well today, I am more than pleased to share one beginner tips on how to embed a flash swf movie clip in an html file using two methods.

Let's first assume you have saved your flash file as coolclip.swf.

Embed flash swf source code file into an html file using Macromedia Dreamweaver product

This would be the best and easiest way to embed your flash swf movie clip into an html file.

1. Open up your html file in the designed view mode, select your location to place your flash swf movie clips by using mouse's click.

2. Click Insert > Media > Flash

3. Now you may browse to select your swf flash source code (coolclip.swf in our example). Click ok to select it.

Click F12 to preview your flash movie clip embeded in an html file :) notes: The reason why i said this is the simplest way to embed flash swf source code file in the html file is because you do not need to worry about the HTML code itself. PLUS, dreamweaver has taking care of your swf width the height size dimension.

Embed flash swf source code file without any tool i.e. using HTML script

Although a good understanding of an HTML code would be better but it is not necessarily needed. Okay, let's follow 3 steps below to embed the swf source code file in an html file

1. Open up your html file using your favourite editor (notepad would be fine)

2. Select the location you wish your flash swf movie clip to be displayed and place a mouse cursor there by clicking on the location.

3. Type in the following HTML tags to embed your flash swf movie inside the html file.

<object width="550" height="400"> <param name="movie" value="coolclip.swf"> <param name="quality" value="high"> <embed src="coolclip.swf" quality="high" width="550" height="400"></embed> </object>

You have just learnt how to embed a flash swf source code file in an html file. Cheers :) notes: before We conclude this flash for beginner tips how to embed a flash swf movie clip in an html file, I'd like to let you ponder for 10 seconds on why do we have two coolclip.swf instances apear between the object and embed tag?

....Ready?....

OKay, according to Macromedia flash techNote, the <object> tag is for Internet Explorer 3.0 or later users. Whereas <embed> tag is for Netscape Navigator 2.0 or later users. Therefore, ALWAYS remember that you have to have two instances of your swf movie clip file appears in both the <object> tag as well as the <embed> tags to accommodate every users.

To conclude, I'd like to share the link to the Macromedia Flash techNote knowledgebase on <object> and <embed> tag.



Author's URL: cambodiaxp.com

Rate this Material: Bad 1 2 3 4 5 Excellent
print this page tell a friend subscribe to newsletter subscribe to rss

Add comments to "Flash for Beginners - Embed a swf Source Code into an HTML"