Skip to main content

Bug Tracker

Side navigation

#3566 closed bug (fixed)

Opened November 02, 2008 10:30AM UTC

Closed February 07, 2009 03:45AM UTC

element selector return error

Reported by: leohhua Owned by:
Priority: major Milestone: 1.3
Component: selector Version: 1.2.6
Keywords: Cc: leohhua, flesler
Blocked by: Blocking:
Description

the script is :

<script language="javascript">

$(function(){

alert($(document.forms[0]["split"]).length);

});

</script>

<body>

<form>

<ul ><li><input type='radio' name='split' id='split0' value='5'><label for='split0'>1</label></li>

<li><input type='radio' name='split' id='split1' value='2'><label for='split1'>2</label></li>

<li><input type='radio' name='split' id='split2' value='0' dataType="Group" min="1" max="1"><label for='split2'>3</label></li>

</ul>

</form>

</body>

when it run in jQuery1.2.1 ,it return right ,the resutl is 3

but when it run in jQuery1.2.6,it return 1.

Attachments (0)
Change History (2)

Changed November 02, 2008 03:28PM UTC by flesler comment:1

cc: → leohhua, flesler
component: coreselector
need: ReviewTest Case

What?!

You don't describe the situation at all. Can you provide a clear test case ? an html file with all the needed js/html.

No need to include jQuery in the package, just this url http://code.jquery.com/jquery-latest.js.

Changed February 07, 2009 03:45AM UTC by dmethvin comment:2

resolution: → fixed
status: newclosed
document.forms[0].split
is a nodelist collection so maybe that was a problem. This works fine in 1.3 on Firefox, IE8 RC1, and Chrome.