This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Dreamweaver > December 2005 > Controlling .swf with Javascript





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Controlling .swf with Javascript
theliveotakeover

2005-12-14, 10:40 pm

I have seen a lot of tutorials about how you can control an .swf using
javascript within the smae HTML page but is it possible to control an .swf if
the buttons are situated in a separate html page to the flash movie? If so, how?


David Stiller

2005-12-14, 10:40 pm

theliveotakeover,

> I have seen a lot of tutorials about how you can control
> an .swf using javascript within the smae HTML page but
> is it possible to control an .swf if the buttons are situated
> in a separate html page to the flash movie?


How do you mean separate HTML page? Are you talking about two or more
panes of a frameset? Are you talking about a newly spawned browser (a
pop-up window)?

The mechanism for controlling objects in a separate HTML document is the
same as that used for controlling objects in a single HTML document. It
comes down to pathing. If there is a way to identify the window (as in, the
JavaScript window object) of another browser, then the path to the object in
that browser begins with that window's name. In a frameset, the path would
begin with the name assigned to a given frame. In a pop-up, the path would
begin with the object reference returned by the window.open() method.


David
stiller (at) quip (dot) net
"Luck is the residue of good design."


Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews