Bug Tracker

Modify

Ticket #8231 (closed bug: duplicate)

Opened 2 years ago

Last modified 2 years ago

.attr can't change a submit input

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

Description

Changing a submit input element to a button (or perhaps another type) causes jQuery to throw a fatal exception:

$('input[type=submit]').attr('type', 'button'); throws fatal

Working example:  http://jsbin.com/arida/2

Note that it throws an exception (which is why I've wrapped them in a try/catch for the example).

Change History

comment:1 Changed 2 years ago by jitter

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

comment:2 Changed 2 years ago by jitter

Duplicate of #8232.

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.