jQuery [attribute] selector
Example
Select every element with an id attribute:
$("[id]")
Try it »
Definition and Usage
The [attribute] selector selects every element with the specified attribute.
Syntax
$("[
attribute
]")
| Parameters | Description |
|---|---|
| attribute | Required. Specifies the attribute to look for. |
jQuery selector