This tutorial will show you how to insert a Flash (SWF) movie into Apple's iWeb.
Apple's iWeb does not have built-in support for embedding Flash movie files, so the following are steps you can follow to add Flash to your iWeb pages.
If you are using iWeb 08, please see the tutorial for Inserting Flash into iWeb 08.
To insert a Flash file, go the "Insert" menu and choose "Choose...". You can then choose the Flash (swf) file you want to insert into your web page. In this tutorial we have created a Blank page named "Blank", and are inserting a Flash file called "MyFlashMovie.swf".
You should now see an area where your Flash file will be displayed within the page. iWeb lets you insert the Flash movie file, but it sets up the page to play the Flash movie with the QuickTime player instead of the Flash plugin player. We will now need to do some editing so that the Flash swf file plays with the correct Flash player and not Quicktime.
After you are done laying out your page, you will want to go to the "File" menu and choose "Publish to a Folder...". This will output your website to a specified folder.
Now go to the Finder and locate the folder where you just published your site to. You should see something similar to the following. In this tutorial we used the Blank page template and the page is called Blank so there is a Blank.html and Blank_files folder where the content for the page is stored including our Flash file ("MyFlashMovie.swf").
We will now have to manually edit a couple of files in order for our Flash file to be played correctly with the Flash plugin. First we will want to edit the HTML page that is to display the Flash movie. In this tutorial we created a page called Blank, so we will be editing the Blank.html file. You can open and edit the html file in any text editor such as Apple's TextEdit.
In this HTML file you should see something simliar to the following where it calls a function called "writeMovie1();". This is what iWeb generate in order to display the Flash file.
Now replace the "writeMovie1();" line with "writeFlash1();" as seen below.
Again you can edit this file in any text editor. Once open you should see the "writeMovie1()" function code and you will need to add in the writeFlash function code. You can copy and paste the following into the .js file.
Make the following changes:
When done it should look something similar to the following