Bug Tracker

Ticket #4048 (closed bug: invalid)

Opened 6 years ago

Last modified 6 years ago

the filters for form throw an error

Reported by: pdodge Owned by: john
Priority: major Milestone: 1.3.2
Component: selector Version: 1.3.1
Keywords: unrecognized filter Cc:
Blocking: Blocked by:

Description

While I excute the following expr for each() action, it will throw a error "filter is not a function in line 1938": $(':input:not(:disabled):not([readonly]):not([type="hidden"]):not(:button):not(:reset):not(:submit)', elem).each(function(){});

It does goes wrong at each input element, but it only throw the error after the last one, otherelse, this expr is available in jquery 1.2;

Change History

comment:1 Changed 6 years ago by dmethvin

  • Owner set to john
  • Component changed from core to selector

comment:2 Changed 6 years ago by pdodge

I am sorry, the essential problem is not this selector, that's the error from the checkbox, as follow: <input type="checkbox" name="mycheck" value="1">

when execute the script: elemname='mycheck'; re=$('input[name="'+elemname+'"]').is(":checked");

It will throw the error filter is not a function in line 1938; this checkbox doesn't throw error while it execute lonely, but it will throw the error as put into a prototype of object, this error is cause by the "is()" method, if replace it with .attr('checked'), that's all right.

comment:3 Changed 6 years ago by pdodge

There is a precondition, I have rewrited the ":" expression like this: $.extend($.expr:?, {

checked: 'a.checked
a.selected jQuery.attr(a, "selected")',

});

but the error will not happen in jquery 1.2.6;

comment:4 Changed 6 years ago by dmethvin

  • Status changed from new to closed
  • Resolution set to invalid
Note: See TracTickets for help on using tickets.