Change a flash on the fly.

D

Defacta

Hi!

Is it possible to change the content of a flash object with javascript
to change a video without having to reload all the page...

The HTML source of the flash is:

<div id="header">
<script type="text/javascript"> AC_FL_RunContent('codebase','http://
download.macromedia.com/pub/shockwave/cabs/flash/
swflash.cab#version=7,0,19,0','width','776','height','96','align','middle','src','flash/
menu','quality','high','bgcolor','#ffffff','name','flash/
menu','allowscriptaccess','sameDomain','pluginspage','http://
www.macromedia.com/go/getflashplayer','movie','flash/menu' );
</script>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/
swflash.cab#version=6,0,29,0" width="718" height="141">
<param name="movie" value="flash/video1.swf">
<param name="quality" value="high">
<embed src="flash/video1.swf" quality="high" pluginspage="http://
www.macromedia.com/go/getflashplayer" type="application/x-shockwave-
flash" width="718" height="141"></embed>
</object>
</noscript>
</div>

Thanks,
Vincent.
 
B

Bernhard Sturm

Defacta said:
Hi!

Is it possible to change the content of a flash object with javascript
to change a video without having to reload all the page...

beg your pardon? what do you want to achieve? If you want to change a
video use a video-editor, if you want to edit a flash-file, then use
flash. Why would you want to use JS for any of the above? JS is
client-side, your flash-object is server-side...

bernhard
 
C

cwdjrxyz

Hi!

Is it possible to change the content of a flash object with javascript
to change a video without having to reload all the page...

The HTML source of the flash is:

<div id="header">
<script type="text/javascript"> AC_FL_RunContent('codebase','http://
download.macromedia.com/pub/shockwave/cabs/flash/
swflash.cab#version=7,0,19,0','width','776','height','96','align','middle','src','flash/
menu','quality','high','bgcolor','#ffffff','name','flash/
menu','allowscriptaccess','sameDomain','pluginspage','http://www.macromedia.com/go/getflashplayer','movie','flash/menu');
</script>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/
swflash.cab#version=6,0,29,0" width="718" height="141">
<param name="movie" value="flash/video1.swf">
<param name="quality" value="high">
<embed src="flash/video1.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-
flash" width="718" height="141"></embed>
</object>
</noscript>
</div>

If I understand what you want to do, there is no need to use script.
When making the first flash, encode it to switch to another flash
display with onclick or at the end of a flash movie. Then in your page
code, you only have to use the first flash object, and the switching
to another flash display is done automatically.
 
N

Neredbojias

Well bust mah britches and call me cheeky, on Fri, 10 Aug 2007 13:41:23
GMT Defacta scribed:
Hi!

Is it possible to change the content of a flash object with javascript
to change a video without having to reload all the page...

The short answer is "No."

The long answer is "Nooooooooooooooooooooooooooooooo."
 
T

Travis Newbury

Well bust mah britches and call me cheeky, on Fri, 10 Aug 2007 13:41:23
GMT Defacta scribed:



The short answer is "No."

The long answer is "Nooooooooooooooooooooooooooooooo."
 
T

Travis Newbury

The short answer is "No."
The long answer is "Nooooooooooooooooooooooooooooooo."

Actually both the long and short answers are yes. You can easily do
that using FSCommand or the newer Externalinterface class. Both allow
javascript/Flash communication, and were designed to perform
functionality just like this.

The real question is why would you do it like that rather than using
Flash itself. (based on the description of what they are trying to do)
 
N

Neredbojias

Well bust mah britches and call me cheeky, on Mon, 13 Aug 2007 13:10:48 GMT
Travis Newbury scribed:
Actually both the long and short answers are yes. You can easily do
that using FSCommand or the newer Externalinterface class. Both allow
javascript/Flash communication, and were designed to perform
functionality just like this.

You can change a Flash movie once it's loaded to another flick _without_
reloading the page? -Ain't seen it and ain't convinced.
The real question is why would you do it like that rather than using
Flash itself. (based on the description of what they are trying to do)

Maybe they're just wierd.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,038
Latest member
OrderProperKetocapsules

Latest Threads

Top