getElementsByTagName returning strings
<p>My ultimate goal here is to get a list of radiobuttons and check/uncheck them. Here is my code:</p>

<pre><code>    for (var radio in document.getElementsByTagName('input')) {
        if(typeof (radio) != "string")
            alert(radio);
    }
</code></pre>

<p>The <code>alert</code> never gets called.</p>

<p>The call to document.getElementsByTagName returns a list of strings numbered from 0 to the length of the list, so all of their properties (type, id, etc) are undefined and I can't really do much with them.</p>

<p>Am I doing something wrong here? Why aren't objects being returned for these elements?</p>

<p>This is in firefox 4 and chrome, if that helps.</p>
