Odd jQuery behavior in IE
<p>I have a span element that replaces a checkbox so I can style it. I also have a label tag; when clicked it should fire the span's click event as if the user has just clicked the span element.  In other words - I'm mimicking the label/checkbox relationship with label/span.</p>

<p>This functionality works as intended in Firefox and Chrome but not IE.  In IE 7 and 8, clicking the label does nothing and seems to generate some odd attribute in the source:</p>

<pre><code>&lt;span class="checkbox" id="Vechicle-1" jQuery15105041923284548672="2"/&gt;
&lt;label class="large text-left" for="Vechicle-1" jQuery15105041923284548672="24"&gt;
</code></pre>

<p>In IE 9 I do not see the jQuery string appended and 2x clicking the label will fire off the span's click event.</p>

<pre><code>$('.checkbox').click(function () {
    $(this).toggleClass('checked');

    if ($(this).hasClass('checked')) {
        $('#checkbox-' + $(this).attr('id')).attr('checked', 'checked');
    } else {
        $('#checkbox-' + $(this).attr('id')).removeAttr('checked');
    }
});

$('label').click(function () {
    $('#' + $(this).attr('for')).click();
});
</code></pre>

<p>Any idea what's causing this behavior?</p>
