Targeting class name - "Object doesn't support property or method"
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/10484467/ie-8-object-doesnt-support-property-or-method-getelementsbyclassname">IE 8: Object doesn’t support property or method ‘getElementsByClassName’</a>  </p>
</blockquote>



<p>I've got a table with generated divs placed within each td, each have a generated classname example: "c1" I can drag say "c1" to another cell I want it to update the textbox (class = cell).</p>

<pre><code>alert(target_cell.className);

//var cellTxt = target_cell.querySelectorAll('.cell');       
var cellTxt = target_cell.getElementsByClassName('cell')[0];

cellTxt.setAttribute('value', target_cell.className);
alert(cellTxt.value);
</code></pre>

<p>The target_cell is the new cell but it throws up the error "Object doesn't support property or method" when it tries to update it. I get the same error in IE 8 &amp; 9 using either cellTxt options.</p>

<p>Any Ideas?  </p>
