Poprosím ak niekto poradí ako zastaviť prehrávač aby sa sám nezapínal ale fungoval len na manuálne zapnutie cez button. Môj script:
/* Background Music */
var songs = ['assets/danosongs.com-magicghost.mp3','assets/danosongs.com-magicghost.ogg'], // First: mp3, second: ogg; Music by Dan-O at DanoSongs.com
autoplay = false, // Boolean, set to false if you don'T want to autostart it
startingVolume = 0.4, // A number between 0 and 1
/* Background Slider */
sliderSettings = {
auto: true, // Boolean: Animate automatically, true or false
speed: 1000, // Integer: Speed of the transition, in milliseconds
timeout: 4000, // Integer: Time between slides, in milliseconds
random: false, // Boolean: Randomize the order of the slides, true or false
},
/* Sticky Menu */
stickyMenu = false, // Use sticky menu? Set to true to turn on
/* Index text slideshow interval */
indexInterval = 4000,
/* Maps */
mapAddress = 'Downtown Dubai';
/**********************
* Don't edit below
*********************/
var player, portfolio, sliderDir = false;
$(window).load(function(){
/* Background music */
player = new Player;
$('#music_toggle').click(function(){
if($(this).hasClass('play')){
player.player.pause();
$(this).removeClass('play');
$.cookie('autoplay', 'false');
}
else{
player.play();
$(this).addClass('play');
$.cookie('autoplay', 'true');
}
});
autoplay = $.cookie('autoplay') === 'false' ? false : true;
if(autoplay){
$('#music_toggle')[0].click();
}
Ďakujem vopred