title: IE bug Invalid Source HTML5 audio - workaround
body: <p>I (and about a million others) have found a bug in IE11 (not sure if other versions have the same bug) where, if you create an HTML5 audio tag, the browser reports &quot;Invalid Source&quot; no matter what. I've tried every combination I can think of with no luck. So far:</p>
  <ul>
  <li>Changing the HTML end tags from self-closing to explicit</li>
  <li>Changing the file name to eliminate any odd characters</li>
  <li>Changing the audio sub format to every possible setting</li>
  <li>Adding an explicit URI (&quot;http:// ...&quot;)</li>
  <li>Disabling all plugins (there were on the stock plugins)</li>
  <li>Trying every possible audio format</li>
  <li>Defining the MIME type</li>
  <li>Changing the audio tag's parameters.</li>
  <li>Changed the IIS settings to include the MIME types.</li>
  </ul>
  <p>I have checked Microsoft's &quot;Connect&quot; website. They make the claim that it is not reproducible, but hundreds of thousands of Google results suggest otherwise.</p>
  <p>Is this not possible at all? ALL other latest &amp; greatest browsers I tried work (Firefox, Opera, Safari, Chrome). No solutions work.</p>
  <p>Here's the code:</p>
  <pre><code>    &lt;%@ Page Language=&quot;VB&quot; AutoEventWireup=&quot;false&quot; CodeFile=&quot;AudioPopupPlayer.aspx.vb&quot; Inherits=&quot;AudioPopupPlayer&quot; %&gt;
  
  &lt;!DOCTYPE html&gt;
  
  &lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;
  &lt;head runat=&quot;server&quot;&gt;
      &lt;title&gt;&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
          &lt;div style=&quot;padding-top: 30px; margin: auto; width: 300px;&quot;&gt;
          &lt;asp:Literal ID=&quot;litVoiceOver&quot; runat=&quot;server&quot;&gt;&lt;/asp:Literal&gt;&lt;/div&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  <p>Code behind:</p>
  <pre><code>Partial Class AudioPopupPlayer
  Inherits System.Web.UI.Page
  
  Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
      Dim VoiceOverFileName As String = Request.QueryString(&quot;vo&quot;)
      If VoiceOverFileName.Length &gt; 0 Then
          Dim root As String = HttpContext.Current.Request.Url.GetLeftPart(UriPartial.Authority) + ResolveUrl(&quot;~/&quot;)
          Dim audiosource As String = &quot;&lt;audio id=&quot;&quot;VoiceOver&quot;&quot; autoplay=&quot;&quot;autoplay&quot;&quot; preload=&quot;&quot;preload&quot;&quot; controls=&quot;&quot;controls&quot;&quot;&gt;&lt;source src=&quot;&quot;&quot; &amp; root &amp; &quot;audio/&quot; &amp; VoiceOverFileName &amp; &quot;.ogg&quot;&quot; type=&quot;&quot;audio/ogg&quot;&quot; &gt;&lt;/source&gt;&lt;source src=&quot;&quot;&quot; &amp; root &amp; &quot;audio/&quot; &amp; VoiceOverFileName &amp; &quot;.mp3&quot;&quot; type=&quot;&quot;audio/mpeg&quot;&quot; &gt;&lt;/source&gt;&lt;source src=&quot;&quot;&quot; &amp; root &amp; &quot;audio/&quot; &amp; VoiceOverFileName &amp; &quot;.wav&quot;&quot; type=&quot;&quot;audio/wav&quot;&quot; &gt;&lt;/source&gt;&lt;/audio&gt;&quot;
          Me.litVoiceOver.Text = audiosource
      End If
  End Sub
  
   End Class
  </code></pre>
  <p>And, finally, a screenshot (in IE11) showing that the HTML is rendered perfectly, yet I still get the dreaded &quot;Invalid Source&quot; message (NOTE: copying and pasting the link causes the audio file to play - go figure).</p>
  <p><img src="https://i.stack.imgur.com/2zYme.png" alt="bug in IE 11" /></p>