Forum Moderators: open

Message Too Old, No Replies

Communicating between Flash and HTML

Can HTML tell SWF go to a specific frame within a specific movieclip?

         

glaze

4:44 pm on Aug 19, 2004 (gmt 0)

10+ Year Member



Can I insert code into my HTML page that tells my SWF to gotoAndPlay a specific frame in a specific Movie Clip?

Thanks!

drbrain

5:01 pm on Aug 19, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try the flash seek bar:

[squarefree.com...]

glaze

5:33 pm on Aug 19, 2004 (gmt 0)

10+ Year Member



That doesn't look like what I need.

Right now I'm using the code below to go to a specific frame label (client) on the main timeline. The code is put within the object tag in the HTML page.

<param name=movie value=../images/header.swf?section=client>

I need to find out if and how I can target a specific frame within a MovieClip.

Thanks.

korkus2000

6:20 pm on Aug 19, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



So are you looking for an html event to trigger the gotoandstart or do you just want it to happen on load within the object tag?

drbrain

6:42 pm on Aug 19, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



No, its in there.

flash.GotoFrame(frame);

glaze

6:52 pm on Aug 19, 2004 (gmt 0)

10+ Year Member



I have ten HTML pages in the site. For each page I will have the same SWF, however, I want each page (on load) to go to a specific frame within a movie clip in the SWF.

Thanks for the help guys!

drbrain

8:11 pm on Aug 19, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Err, its in the flash seek bar I just told you about:

<script>
function jump_to(frame_number) {
flash = document.getElementById('flash');
flash.GotoFrame(frame_number);
flash.Play();
}
</script>

<body onload="jump_to(<frame number>);">

<object id="flash" ...></object>

</body>

glaze

10:14 pm on Aug 21, 2004 (gmt 0)

10+ Year Member



thanks drbrain! sorry you had to spell it out for me. I missed the point of that link until I actually downloaded the .js.