I have done it in the past by creating the "popup" function in the same web
page that launches the Flash animation:


<script language="_javascript_">
function launchWin( winURL, winname, width, height ) {
var newWindow;
winOptions = 'width='+width+',height='+height;
winOptions += 'toolbars=0,menubar=0,scrollbars=1,status=1,resizable=1';
var newWindow = window.open( winURL, winname, winOptions );
newWindow.opener = self;
newWindow.focus();
}

Then, putting the link (text, button, image, etc.) in the flash movie as:
"_javascript_:launchWin( 'myPopup.cfm', 'helpwindow', 500, 200 );"


That goes in the actionscript "onClick" or "onButtonUp" or whatever the
function is in AS to handle a user click.


Basically, just have your popup code in the HTML for the page that has the
flash movie in it and then reference it like any other link inside the flash
movie.

-----Original Message-----
From: Bryan Stevenson [mailto:[EMAIL PROTECTED]
Sent: Friday, April 02, 2004 1:27 PM
To: CF-Talk
Subject: OT: Flash pop-up help

Hey All,

I want to open a window from in side a Flash movie using _javascript_.  So far
all I've been able to do is open the window using the getURL() function with
a target of "_blank".  This gets me the window I want, but when I use
"window.close();" in the pop-up window to allow users to close it, that
annoying "The web page you are viewing is trying to close this window.  Do
you want to close this window?" alert window.

My assumption is that because the pop-up was not opened via _javascript_ that
it whines when closed with _javascript_.  All my other pop-ups that are popped
from a regular web page (not from inside Flash) using _javascript_ do not show
this alert when being closed via _javascript_.  Of course it may also have
something to do with the pop-up being launched from inside Flash.

Any thoughts would be greatly appreciated!!

Cheers

Bryan Stevenson B.Comm.
VP & Director of E-Commerce Development
Electric Edge Systems Group Inc.
t. 250.920.8830
e. [EMAIL PROTECTED]

---------------------------------------------------------
Macromedia Associate Partner
www.macromedia.com
---------------------------------------------------------
Vancouver Island ColdFusion Users Group
Founder & Director
www.cfug-vancouverisland.com
  _____
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to