I upgraded a project recently from 1.7.2 of jQuery to 1.8.2 and began testing my pages. On one of my pages I was getting the following error:
Doing a little research I discovered that in the 1.8 release of jQuery they deprecated the :radio and other such pseudo-class selectors. The preferred method moving forward is to use the equivalent CSS selector of [type=radio].
Here’s the jQuery 1.8 release notes and the ticket describing this change.
Why the removal?
From their radio selector page under the Additional Notes section:
:radio is a jQuery extension and not part of the CSS specification, queries using
:radio cannot take advantage of the performance boost provided by the native DOM
querySelectorAll() method. For better performance in modern browsers, use
And from the ticket page:
Deprecate (for eventual removal) the input type selectors: :file :image :password :radio :reset :submit :text -- They are basically aliases to [type="file"] [type="image"] but can't use querySelectorAll - I think having these selectors around in the long term future is entirely unnecessary and confusing.