I am checking for the presence of a class in table tr elements like:
<tr class="row1 head4"></tr>
by the statement:
if (that.next().hasClass('.head'+nextRow)){}
else if (that.next().hasClass('.head'+(nextRow+1))){}
nextRow has values ranging from 1 to 5. but it isnt working. is the syntax wrong?
You don’t need a fullstop prepending class name. The full stop is only required when using a “normal” jquery selector.