Help redirecting to a different url after an embedded movie is done playing
July 24, 2006 8:00 AM Subscribe
I have a webpage that has an embedded movie (wmv) that starts when the page loads. My client is wanting the page to redirect to a different url after the movie is done playing instead of the movie just sitting there in the done position. Please help as my googlefu has failed me on this and I am not familiar enough with movies to figure this out. I am sure there is some javascript that can do this, but I cannot find it.
For those that are a little confused I hope this helps:
Client visits domain.com/movie.html and when the movie is done playing it needs to go to domain.com/done.html
My Flash chops are weak, but I believe it's possible to put the wmv movie into a Flash, and you then put the redirect in the Flash, after the movie. Note that you're embedding the Flash into your page instead of wmv.
posted by Artful Codger at 8:25 AM on July 24, 2006
posted by Artful Codger at 8:25 AM on July 24, 2006
Yeah, the best way is probably to have the WMV do the redirect if you can.
Keep in mind that it might not work on a Mac with the Flip4Mac plug-in installed (that allows QuickTime to play WMVs -- this is Microsoft's official Mac solution now). I'm pretty sure Flip4Mac only does video and ignores things like URL redirects. I might be happily wrong, though.
posted by kindall at 8:26 AM on July 24, 2006
Keep in mind that it might not work on a Mac with the Flip4Mac plug-in installed (that allows QuickTime to play WMVs -- this is Microsoft's official Mac solution now). I'm pretty sure Flip4Mac only does video and ignores things like URL redirects. I might be happily wrong, though.
posted by kindall at 8:26 AM on July 24, 2006
There's some info here, msdn page here. It looks like WMV sends a "playstatechange" event that is equal to 8 ("MediaEnded"), when the "Media item has completed playback". Hope this helps.
posted by null terminated at 11:21 AM on July 24, 2006
posted by null terminated at 11:21 AM on July 24, 2006
Navigation which automatically jumps between pages sounds like rather poor usability to me, what if the user wants to play the movie again or copy the URL or visit that second page before the movie has finished or just use the BACK button?
Also a lot of media players now have an option to ignore URL redirects.
I would talk the client out of this idea.
posted by Lanark at 12:22 PM on July 24, 2006
Also a lot of media players now have an option to ignore URL redirects.
I would talk the client out of this idea.
posted by Lanark at 12:22 PM on July 24, 2006
This thread is closed to new comments.
posted by mathowie at 8:02 AM on July 24, 2006