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']) Commented 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/

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.