KTA
01-09-2008, 05:11 AM
This actualy works if user decides not to turn off the sound when first arriving to the site.. I was hoping that if it was turned into an "if else" statement it may solve my problem.
Problem: I have background music playing when entering the site however if the user turns off the sound when they arrive into the site THEN were to click on the video the sound would start up again after the video ends.
I want it to say: Hey if the music is on then turn it back on after the video ends BUT if the music is off leave it off when the video ends.
Lastly the video is not on auto play the user needs to press play.
var enventListener = new Object();
enventListener.playing= function(evntObj){
_root.music.stop();
}
player.addEventListener("playing",enventListener);
var enventListener = new Object();
enventListener.complete= function(evntObj){
_root.music.start(0,999);
}
player.addEventListener("complete",enventListener);
THANKS FOR ANY ADDITIONAL HELP!
Problem: I have background music playing when entering the site however if the user turns off the sound when they arrive into the site THEN were to click on the video the sound would start up again after the video ends.
I want it to say: Hey if the music is on then turn it back on after the video ends BUT if the music is off leave it off when the video ends.
Lastly the video is not on auto play the user needs to press play.
var enventListener = new Object();
enventListener.playing= function(evntObj){
_root.music.stop();
}
player.addEventListener("playing",enventListener);
var enventListener = new Object();
enventListener.complete= function(evntObj){
_root.music.start(0,999);
}
player.addEventListener("complete",enventListener);
THANKS FOR ANY ADDITIONAL HELP!