0

I'm doing a project where I can't host the actual audio files in the site folder so I have to link to a gofile mp3. When I do this playback works great on localhost but as soon as I upload to server it will not play the mp3. Is there something I am doing wrong?

Here is an example of where put in the external link and when it is asked to play.

  var sound1 = new Audio('https://srv-file16.gofile.io/download/LRQQr1/When%20the%20Summer%20Ends%20-%20Official%20Audio.mp3'); 

         if(form.userid.value == "GREY")
 {
    $(".modalDialog").css({"opacity":"0","pointer-events":"none"});
    setTimeout(location.reload.bind(location), 206000);

    sound1.play()

    rainbow.style.visibility='hidden'
    forehead.style.visibility='hidden'



  }
  • The download link seems protected. This method should work, but I think that the problem lies in the gofile service. – Emiel Zuurbier May 08 '20 at 15:55
  • I removed the password for the gofile link. I'll report back in the mean time to update you if it has failed. Do you have any other suggestions other than gofile that may work if it is the actual service itself? –  May 08 '20 at 15:58
  • 1
    Amazon S3 is one you might try. But other than that I wouldn't know. Why can't you host the file on your server? – Emiel Zuurbier May 08 '20 at 16:04
  • I don't want temporary mp3's on my server but the main reason is that a friend challenged me to do this without hosting the file locally :/ –  May 08 '20 at 16:21

0 Answers0