Bug Tracker

Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#9670 closed bug (duplicate)

selectedIndex returns undefined

Reported by: [email protected] Owned by: [email protected]
Priority: low Milestone: 1.next
Component: attributes Version: 1.6.1
Keywords: Cc:
Blocked by: Blocking:

Description

This works OK in 1.5.2 but returns undefined in 1.6.1

<select name=”testselect” id=”testselect” onChange="alert($(this).attr('selectedIndex'))"> <option value="val1">Value 1</option> <option value="val2">Value 2</option> </select>

Change History (3)

comment:1 Changed 10 years ago by Rick Waldron

Component: unfiledattributes
Owner: set to [email protected]
Status: newpending

Thanks for taking the time to contribute to the jQuery project! Please provide a reduced jsFiddle test case to help us assess your ticket!

Additionally, be sure to test against the jQuery Edge version to ensure the issue still exists. To get you started, I've created this boilerplate: http://jsfiddle.net/rwaldron/da3nM/ Open the link and click to "Fork" in the top menu.

comment:2 Changed 10 years ago by timmywil

Priority: undecidedlow
Resolution: duplicate
Status: pendingclosed

selectedIndex is not an attribute.

comment:3 Changed 10 years ago by timmywil

Duplicate of #9088.

Note: See TracTickets for help on using tickets.