Forum Discussion
Background Audio Cool Trick
Hi All,
Just wanted to share a way to add audio across all slides in Storyline 2 There are a few posts on here about this, and I found this method to be super simple.
**Please note that this is just a cool trick, and not a built in feature of Storyline 2.
Publish your course, open the story.html file with Notepad, scroll to the bottom and add this code
<audio src="YOURAUDIOHERE.mp3" preload="auto" autoplay loop></audio> with a space before the </body> and place your audio file into the published output folder and there you go. That is it.
Here is an example, http://bit.ly/1sy5dkV and the output folder is attached.
Have fun!
Hello, Everyone! ✨
I'm happy to share that we have released a new update for Storyline 360 (Build 3.79.30834.0).
In this update, we have an enhancement where:
- Background audio is now supported in the published video output.
As a first step, I recommend updating Storyline 360 to the latest version. Here's how:
If you have any questions, please let us know in this thread or privately in a support case.
Have a great day!
- CatherineBeg856Community Member
Has anyone has this work when you publish to html5 only? I can not for the life of me get it to work. I have uploaded the scorm file.
- MaudBernies-bb7Community Member
Bonjour, y a-t-il un autre moyen depuis cette possibilité d'ajouter une musique sur l'ensemble du prpjet ou c'est le seul?
Merci!
- IrinaIrina-27e6Community Member
Hi everyone!
I am making an interactive video manual, where speaker says some words, what the learner should do, some special extra things etc., then video pauses and user should do what he/she was told to. I need a background music to work even when the video is stopped. And I can do it, BUT I need the background music to stop somehow when I need it to stop and I have no idea, how to do it.
Here are some of my thoughts:
1.I have created a variable 'VideoFinished' in SL, that changes its value once user completed the necessary task. It's initial value is 'no', once user double clicks the first hotspot it turns to 'yes'
2. Added trigger "Execute Javascript when timeline starts on the slide"
3. JS is supposed to take the variable 'VideoFinished' from the course and use it as a condition whether to play music or not.
If I do not use any conditions on JS, audio is playing fine, it is looped, volume is adjusted.
However once I add a 'while' to JS, no audio is played at all.
Can someone please let me know, what am I doing wrong? Here is JS, var video - is a variable in JS that should be equal to the 'VideoFinished' of SL:
var player=GetPlayer();
var video=player.GetVar('VideoFinished');while (video=no) {
var audio = new Audio()
audio.src = 'story_content/5kxW8RMEV8D_44100_48_0.mp3'
audio.play ()
audio.loop = true
audio.volume = 0.5
} - JacquelineFi900Community Member
Hi @Matthew Bibby,
I was able to use the code it works great. Any idea how to control the volume? Is there a script I can use?
- KarimBelkacemCommunity Member
Hi all !
For the Volume add propriety "volume" in tag audio. Example :
<audio src="YOURAUDIOHERE.mp3" volume="0.9" preload="auto" autoplay loop></audio>I hope help you :)
- BorisKulebaCommunity Member
Hi everyone, I’m new to Articulate Storyline, I can’t believe how easy it is to learn. Yesterday I installed the program and today I have an interactive explainer video! :) I'm an animator by profession, I don't know much about coding, java, html and it's not clear to me why this part of the code doesn't work in Chrome , Edge either. Music is heard in IE and not in others. Thank you all and all the best
Boris - AsmaSayaniCommunity Member
Does not work for me:(
- MatthieuRoche-6Community Member
Hi ! This trick works for me (I had to insert the code in the .index_lms.hmtl file though, not the story.html) but I would like to know if I could stop it (or mute it) on specific slides.
To be more precise, I have a video on a slide in which I would like to mute the background music I added.
- MaribethChristeCommunity Member
Hi there,
I used this method last year and now am trying again on a new project, which is not working. Has something changed with Articulate 360 to prevent this trick?
- AnnaLaMontCommunity Member
It still works, you just need to paste the script into anything you can open with Notepad, depending on your output (SCORM or TinCan), like story, index-lms, etc.
- MaribethChristeCommunity Member
Thanks! I actually heard from Articulate that it does not work due to browser restrictions, so I'm trying to figure out a workaround via Java Script