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!
- BrigidNaglichCommunity Member
I'm able to save my file as html5, added the code for seamless audio in notepad, and can hear the audio. Once I upload the file to AWS, the audio is fine. Once I add the link to Canvas, the audio no longer plays. I'm working on Mac Parallels, not sure if that's part of the problem?
Appreciate any feedback, thanks -
- AshishNegi-d8e6Community Member
Thanks for the sharing.
QQ: Is this code working fine in Storyline 3 as well. I find challenge to work it out in Storyline 3.
Attached is the HTML5 file.
Help!
- com01farzinCommunity Member
hi
how insert background music in storyline3?
- FredGoodCommunity Member
I use SL3 and I got this to work, but I had to struggle a bit to learn how to do it. Here's what I did:
Note that when I would publish it created a folder that contained many files, two of which we will focus on:
story.html
and
story_html5.html---
1. In your story.html file, open it with notepad (or your favorite html editor) BEFORE (NOT BETWEEN) the </body> and </html> tags, place this code snippet:<audio src="NAMEOFYOURAUDIOFILE.mp3" preload="auto" autoplay loop></audio>
---
2. In your story_html5.html file, open it with notepad (or your favorite html editor) BETWEEN (NOT BEFORE) the </body> and </html> tags, place this code snippet:<audio src="NAMEOFYOURAUDIOFILE.mp3" preload="auto" autoplay loop></audio>
***I made sure to put a space and a hard return after the code snippet, as was instructed in the original post, and that appeared to help.
---
3. Make sure to put the mp3 file in the folder at root level (meaning in the same folder as the story_html5.html file). Make sure the file name of the mp3 matches the name in the code precisely!
- KavithaNair-e79Community Member
I am unable to use any of these methods. Do we have an update on how to add music to run through all slides?
- OwenHoltSuper Hero
as long as you are not developing for the mobile player, the javascript solution still works great if you use some interaction to start it. The user has to interact with the page to get around the chrome updates.
- CherylPowellCommunity Member
Code did not work for me either.
- GreeshmaThom564Community Member
Hi,
It is not working for me. I added that code in the story.html file before </body>. But it doesn't work for me. What would be the reason?
Thanks!
- TeoKarCommunity Member
a pity that there is no regular solution yet
- WeeThansomCommunity Member
Sorry to bring this back, but is there a way to only loop the background music for specific set of slides? For example, I have 1-50 slides, I only want to loop the music in slide 5-8. Thank you.
- GreeshmaThom564Community Member
Thanks for your response.
Can you explain how to loop the background music?
Thanks,
Greeshma
- GiuliaBCommunity Member
If you're publishing in html5, you should follow a comment in the first page that explain how to add the html tag in the story_html5 file! :)
- WeeThansomCommunity Member
Any help with this is greatly appreciated.
- PedroFernandezCommunity Member
Looks like Chrome 70 and later broke this for us :(
This works on Edge but Chrome will not play the music.