Bug Tracker

Modify

Ticket #1477 (closed bug: invalid)

Opened 6 years ago

Last modified 5 years ago

.val() on mouseup in IE

Reported by: Draeli Owned by:
Priority: major Milestone: 1.2.2
Component: event Version: 1.1.3
Keywords: Cc:
Blocking: Blocked by:

Description

I use basic JQuery 1.1.3.1. I have an element :

<select id="emblem"> <option value="0">1</option> <option value="1">2</option> ...

When i do : $("#emblem").val();

under Firefox no problem, 0 or 1 is return when is select by mouseup event, but under IE7 (7.0.6), when i select by same event, result is always 0.

Attachments

jquery_test.html Download (782 bytes) - added by davidserduke 5 years ago.
test case

Change History

comment:1 Changed 6 years ago by Draeli

I have same problem with : $("#emblem").attr("value"); under Firefox that ok, under IE7 ... always 0 value is return.

comment:2 Changed 6 years ago by john

  • Summary changed from About IE7.0.6 to .val() on mouseup in IE

comment:3 Changed 6 years ago by john

  • Component changed from core to event

Changed 5 years ago by davidserduke

test case

comment:4 Changed 5 years ago by davidserduke

  • need changed from Review to Patch
  • Milestone changed from 1.1.4 to 1.2.2

I'm not sure how this can be fixed. It appears IE just hasn't updated the selected values yet when it fires the mouseup event. A work-around is to use the change event which seems to work fine.

I'll leave it open for now if anyone has any ideas.

I've attached a test case that was written based largely on the description.

comment:5 Changed 5 years ago by brandon

  • Status changed from new to closed
  • Resolution set to invalid

The change even would be more appropriate in this situation.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.