title: elementID.style.display='block' not work in chrome but working in firefox
body: <pre><code>function loadMyitem(output, counter, msg, FileQuery) {
  
      //alert(output)
      if( window.XMLHttpRequest )
      {
          xmlhttp = new XMLHttpRequest();
      } else {
          xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
      }
      xmlhttp.onreadystatechange = function () {
          if (xmlhttp.readyState == 1) {
              msg.style.display = 'block';
              msg.innerHTML = "";
          } else if (xmlhttp.readyState == 4 &amp;&amp; xmlhttp.status == 200) {
              msg.style.display = 'block';
              msg.innerHTML = "";
  
              var respStr = new Array();
  
              respStr = xmlhttp.responseText.split('|');
              optStr = output.split('|');
              var CC1 = $(counter).val();
              for (i = 0; i &lt; respStr.length; i++) {
                  //alert(respStr[i]); 
                  document.getElementById(optStr[i] + CC1).value = respStr[i];
              }
          }
      }
  
      //document.getElementByID(msg).innerHTML=inputText;
      xmlhttp.open("get", FileQuery, true);
      xmlhttp.send();
  }
  </code></pre>
  
  <p>This works on Firefox, but when I execute this function in chrome or opera then its give error:</p>
  
  <blockquote>
    <p>Uncaught TypeError: Cannot set property 'display' of undefined</p>
  </blockquote>
  
  <p>What is the problem in this function?</p>