1

I would like to select elements using Jquery. I have two patterns - input[aria-invalid='true'] and select[aria-invalid='true']. How can I write those two patterns in one Jquery selector?

1
  • Assuming you want the union of the elements: $("input[aria-invalid='true'],select[aria-invalid='true'])
    – HashPsi
    Aug 5, 2015 at 16:43

1 Answer 1

1

You can achieve this by

$("input[aria-invalid='true'], select[aria-invalid='true']")

For reference - https://api.jquery.com/multiple-selector/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.