
Page 1 of 1
Evgueni Strok
This user is yet to take control of their account and provide a biography. If you are the author of this article, please contact us via support AT actionscript DOT org.
View all articles by Evgueni StrokDifficulty Level: Beginner
Requirements: Flash 4 or above
Download the source for this tutorial.
The code for this tutorial is divided into 2 parts HTML code and FLASH code
Part 1 -- FLASH code
In actions choose the GET URL function and paste in following code:
javascript:openNewWindow('somePage.html','thewin',
'height=100,width=250,toolbar=no,scrollbars=yes');
Where somePage.html is the filename or URL of the page or site you wish to pop up.
Note: The above code is spread over two lines for tutorial neatness only. In Flash it need be on only one line.
Part 2 ---HTML code
Paste this code exactly as it appears below, between the HEAD tags in the HTML source.
<script language="JavaScript">
function openNewWindow(URLtoOpen, windowName, windowFeatures) {
newWindow=window.open(URLtoOpen, windowName, windowFeatures);
}
</script>
Add the following parameter inside the <EMBED> tag in your HTML page which houses the SWF file:
swLiveConnect=true NAME=yourmovie.swf
Note: This is important as it allows the Flash movie to communicate with the JavaScript code.

