Click to See Complete Forum and Search --> : FlashMX & Javascript


gillscotter
12-02-2003, 10:48 AM
Hi has anyone any tips for me on importing Flash MX into a Dreamweaver application but manipulated with Javascript so depending on what the user enters the correct Flash movie will appear up
I would be sooo thankful if any one has any ideas
Thanks*

96turnerri
12-02-2003, 11:58 AM
what are the variables for giving a different flash movie?
type of browser
screen resolution
or something else?

LittleRed
12-03-2003, 02:45 AM
you can send flash variables from javascript. when you embed the flash movie in your html give it a name as well (ie. name="flashmovie") and then you can use
document.flashmovie.setvariable('variablename','value');
which will set the variable 'variablename' on the root timeline of your movie to 'value'. Then just get your flash movie to detect for this value and change content as appropriate.

if you've got lots of little flash movies to choose from, then you'd probably need a controller movie that detects the javascript variable and then uses loadMovie or whatever to bring in whichever of the actual content movies.

binkyboo
12-03-2003, 08:42 AM
...in addition add

swLiveConnect = true

in the <EMBED src=></EMBED> tag.

LittleRed
12-03-2003, 09:31 AM
but isn't the <embed> tag non-standards compliant? would it work in the <object> tag?

I've not come across it before - what does the swLiveConnect control?

binkyboo
12-03-2003, 09:38 AM
I think Macormedia documents it best.

http://www.macromedia.com/support/flash/ts/documents/flash_to_flash_comm.htm

http://livedocs.macromedia.com/flash/mx2004/main/15_pub39.htm

LittleRed
12-03-2003, 09:40 AM
thanks - I'll have a look at those.