Bug Tracker

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#9612 closed bug (duplicate)

$.attr('defaultSelected') returns undefined instead of true/false

Reported by: anonymous Owned by:
Priority: low Milestone: 1.next
Component: attributes Version: 1.6.1
Keywords: Cc:
Blocked by: Blocking:

Description

$('option').attr('defaultSelected') should return true or false for <option> elements. The attribute appears in the DOM but jQuery returns undefined.

This might have something to do with that attribute being read-only?

Change History (2)

comment:1 Changed 8 years ago by timmywil

Component: unfiledattributes
Priority: undecidedlow
Resolution: duplicate
Status: newclosed

Thanks for taking the time to contribute to the jQuery project! This is a case where prop should be used instead since defaultSelected is not an attribute.

comment:2 Changed 8 years ago by timmywil

Duplicate of #9088.

Note: See TracTickets for help on using tickets.