I have the following code and I'm trying to retrieve the txtboxes where id
does not contain the the word OT
.
<input type="text" id="txtMo1">
<input type="text" id="txtOTMo1">
<input type="text" id="txtTu1">
<input type="text" id="txtOTTu1">
...
...
<input type="text" id="txtMo4">
<input type="text" id="txtOTMo4">
<input type="text" id="txtTu4">
<input type="text" id="txtOTTu4">
...
...
I tried using .find
where id
starts with txt
but it gives me everything (obviously). How do I retrieve only the textboxes where id starts with txt
but does not contain OT
?
.find("input[id ^= 'txt']")