title: Internet Explorer 8 and getElementsByTagName('script') not working
body: <p>Another user suggested a function for converting a string to dom elements then iterating through the string and executing the js.  It works fine just not in IE8, surprising.</p>
  
  <pre><code>function get_script_src_from_string (INPUT_STRING) {
  
    var tempDiv = document.createElement('div');
    tempDiv.innerHTML = INPUT_STRING;
  
    var scripts = tempDiv.getElementsByTagName('script');
    var script_urls = [];
    for (var i=0; i&lt;scripts.length; i++) {
      script_urls.push(scripts[i].src);
    }
    return script_urls;
  
  }
  </code></pre>
  
  <p>I am simply passing in a test string:</p>
  
  <pre><code>get_script_src_from_string('&lt;div class="tester" id="tester"&gt;&lt;script id="tester2" type="text/javascript"&gt;alert("test");&lt;/script&gt;&lt;/div&gt;');
  </code></pre>
  
  <p>If I do a test with</p>
  
  <pre><code>var test = tempDiv.getElementsByTagName('*');
  alert(test.length);
  </code></pre>
  
  <p>All browsers return 2, ie8 returns 1, so it is not recognizing script as a tag.  Using jquery for this project is not an option unfortunately.</p>