No autoplay on WMP during same session

A

Anthony

Is there a script out there that will prevent embedded Windows Media
Player that autoplays a video from replaying when a person comes back
to the home page during the same session? Maybe a cookie that will
prevent the video from autoplaying again for hour.
 
B

Bart Van der Donck

Anthony said:
Is there a script out there that will prevent embedded Windows Media
Player that autoplays a video from replaying when a person comes back
to the home page during the same session?  Maybe a cookie that will
prevent the video from autoplaying again for hour.

Yes, besides cookies I don't see any immediate possibilities.

Note that Firefox requires the Windows Media Player Firefox Plugin:
http://port25.technet.com/pages/windows-media-player-firefox-plugin-download..aspx
Other non-MSIE browsers might also need an application to be
installed.

How to set and read cookies:
http://www.w3schools.com/js/js_cookies.asp

HTML code to play the movie inline (I would recommend 6.4 for maximum
backwards compatibility):
http://msdn2.microsoft.com/en-us/library/ms983653.aspx

Program logic:

Check if cookie exist.
* If yes, load movie with parameters
<EMBED ... AUTOSTART="0">
<PARAM NAME="autoStart" VALUE="false">
* If no, load movie with
<EMBED ... AUTOSTART="1">
<PARAM NAME="autoStart" VALUE="true">
Then set the cookie

Hope this helps,
 

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,754
Messages
2,569,527
Members
44,998
Latest member
MarissaEub

Latest Threads

Top