Get Checkboxlist selected Item using javascript not working
<p>I have selected 2 items from the <code>checkboxlist</code> with below code which I tried I am getting error as</p>

<blockquote>
  <p>attributes is not defined.</p>
</blockquote>

<p>Here is my code</p>

<pre><code>var checkboxlist = document.getElementById('&lt;%= ddlStatus.ClientID %&gt;');
        var checkOptions =   checkboxlist.getElementsByTagName('input');
        var listSelected = checkboxlist.getElementsByTagName('span');

        for(i = 0; i &lt; checkOptions.length; i++)
        {
            if(checkOptions[i].checked)
            {
                alert(listSelected[i].attributes["STATUS"].value);
            }
        }
</code></pre>

<p>kindly let me know how to get the selected value</p>

<p><strong>UPDATE</strong></p>

<p>Fiddle of the checkboxlist with 2 items selected</p>

<p><a href="https://jsfiddle.net/Lg8w2u7d/" rel="nofollow">JSFiddle</a></p>