Plugins

User login
Can't find a Plugin?

Can't find a Plugin you are looking for? Check out the jQuery Wiki page.

Are you a plugin developer? Please move your plugin over to this site.

Website Bug or Feature Request?

Found a bug on the new jQuery Plugin website? Have a feature request?

Submit it to the jQuery Plugin website issue queue to ensure it is noticed!

JS error when using :blank or :filled in required rule in a form with li elements


Project:Validation
Version:1.5.5
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

JS error "(E || "").replace is not a function" occurs when:

  • within the form element are one or more li elements
  • there is at least one required rule that uses the :blank or :filled selector
  • using jQuery 1.3

What ends up happening is that the li elements are checked against the :blank and :filled selectors (I'm guessing due to Sizzle's bottom-up matching). The li elements have a deprecated "value" attribute, but this is a number not a string, which causes $.trim() to throw an error.

Please see the attached test case.

AttachmentSize
Test case846 bytes

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

#1

Status:active» fixed

I'm now converting whatever is passed to $.trim to a string. Fixes this issue.

#2

Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

#3

Automatically closed -- issue fixed for two weeks with no activity.

#4

I agree with the statement that China and the United States can together drive a global clean energy economy that may define the 21st century! Cool facts for writing a paper in college or university for scientific classes! Online Nutritional Health Science degree AND Web Development degree AND public administration school AND Online school AND sociology degree

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.