You guys really seem to know your stuff and I always find your site very helpful when I'm creating websites, so I'm hoping you can help me with this problem...
Background:
I am an html person not a programmer. I have a site in development that has a custom javascript/jquery slide show that uses jPlayer to play a mp3 with each slide.
The Problem:
The mp3's are not preloading and it's causing a delay that screws up the timing of the slide show. So what I need is some sort of a mp3 preloader or "streamer". jPlayer has a preloader but the audio is being called from the custom slide show script and not the player code. Here is the critical pieces of the slide show script. Can you help me figure out the preloading? I would be happy to give a donation to the cause for help.
Code:var photos = [ { "title" : "1 of 2", // title of slide "image" : "slide1.jpg", // background image for slide "audio": "slide1.mp3", // audio file to play with slide "url" : "buy.html", // link url for secondline text "transitionTime":8, // how long to keep slide on screen "firstline" : "Text1", // text to display over slide (css black) "secondline" : "Text2" // text to display over slide (css red) }, { "title" : "2 of 2", "image" : "slide2.jpg", "audio": "slide2.mp3", "url" : "buy.html", "transitionTime":8, "firstline" : "Text3", "secondline" : "Text4" } ]; var stopped = false; function preloadMedia(photosObject) { var audios = ''; for(var i=0 in photosObject) { audios += "<img src='mp3/"+photosObject[i].media+"' >"; } $("body").append($("<div>").html(audios)); }



Reply With Quote

Bookmarks