title: Audio Not Playing - JavaScript
body: <p>I'm trying to set up a client's website to play back an audio file on page load (at his demand, not a preferred feature for me). I have used some simple JavaScript but the audio isn't playing when the page loads. Any ideas why this is happening?</p>
  
  <pre><code>&lt;head&gt;
  &lt;!--other metadata up here--&gt;
      &lt;script&gt;
  function EvalSound(soundobj) {
        var thissound = document.getElementById(soundobj);
        thissound.Play();
      }
      &lt;/script&gt;
  
      &lt;embed src="scripts/audio.wav" autostart=true width=1 height=1 id="audio"
      enablejavascript="true"&gt;
  &lt;/head&gt;
  &lt;body&gt;
    &lt;div id="container" onload="EvalSound('audio')"&gt;
  &lt;!--rest of page&gt;
  &lt;/body&gt;
  </code></pre>