Salient v14.0 (11/15/2021) is out now!

After updating, remember to clear the cache from any performance plugins you have active as well as your browser cache.

Once you've updated your theme, make sure to also update your Salient plugins to get access to the new features.

Click here to view the update guide

View Changelog

Okay
  Print

Add html5 sound to Salient

Add this into the Custom CSS box located in your Salient Options panel (All custom css provided is tested in the Live Browser so it will work as intended . If you cant see any changes make sure there is no red cross in the Custom CSS Box as that syntax error would cause all css below it to not show up on the Frontend):

/*add sound close icon*/
li#nectar-user-account.none .icon-salient-m-user:before {
    content: "\e099" !important;
}

Add this to the Custom JS Box :

<audio controls="" volume="0.5" autoplay="" loop="" id="muzyka">
<source src="https://tomgacz.pl/wp-content/uploads/2020/02/Creative-Showcase-Portfolio-Theme-_8211-Just-another-WordPress-site.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio> 
<script>
  var audio = document.getElementById("muzyka");
  audio.volume = 0.3;
</script>
<script>
var audio = document.getElementById('muzyka');
    var btn = document.getElementById('nectar-user-account');
btn.classList.add("selected");
    
    btn.addEventListener('click', function (e)
{
    e = e || window.event;
    audio.muted = !audio.muted;
        
         if (btn.className == "selected") {
             btn.classList.add("none");
  } else {
    btn.classList.replace("none","selected");
  
  }
        
    e.preventDefault();
}, false);</script>