Bug Tracker

Modify

Ticket #8922 (closed bug: invalid)

Opened 3 years ago

Last modified 3 years ago

.attr("checked","") is setting value to checked

Reported by: Pantz Owned by:
Priority: low Milestone: 1.next
Component: attributes Version: 1.6b1
Keywords: Cc:
Blocking: Blocked by:

Description

 http://jsfiddle.net/3x562/

A blank string (or any string) is setting the value of the checkbox to checked. This seems to be a change in behavior from 1.5.2. Setting the value to false will correct the issue.

Change History

comment:1 Changed 3 years ago by timmywil

  • Priority changed from undecided to low
  • Resolution set to invalid
  • Status changed from new to closed
  • Component changed from unfiled to attributes

We no longer remove the attribute when an empty string is provided as that can be a valid use case for multiple boolean attributes, which leaves them as true in multiple browsers. To set to false, use .attr('checked', false) or preferably .removeAttr('checked').

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.