I know that [开发者_JAVA百科my_attr='my_value']
refers to all elements which have attribute my_attr
with value my_value
.
Is that possible to refer to all elements which have my_attr
attribute (no matter what the value is) ?
Use [my_attr]
alone:
[att] Represents an element with the att attribute, whatever the value of the attribute.
element[attr]
That should do it.
精彩评论