Selecting all items that do not have an id attribute?

How can I select all the elements on a page that does not have an id attribute? What is a selector for this in jQuery?

+6
source share
2 answers

You can use $(':not([id])') . This should work fine.

+9
source

Source: https://habr.com/ru/post/910076/


All Articles