I have this html code
<div class="row">
<div class="anwser " data-index="0-0" data-questionid="Refer_QID" data-type="FormTextBox" data-required="true">
<div class="col-xs-12">
<input class="txtBox alpha hasError" data-index="0-0" type="text" data-anwserid="Refer_ID" maxlength="100">
</div>
</div>
</div>
<div class="row">
<div class="anwser " data-index="0-0" data-questionid="Refer_QID" data-type="FormTextBox" data-required="true">
<div class="col-xs-12">
<input class="txtBox alpha hasError" data-index="0-0" type="text" data-anwserid="Refer_ID" maxlength="100">
</div>
</div>
</div>
I'm trying to do what would have happened if the Input class hasError, he appeared and ROW. Here is my jquery script:
if ($(".anwser input").hasClass('hasError')) {
$(this).parent().css( "border", "2px solid #4f5ca7" );
}
but it does not work. If instead of this I will enter ".anwser" That changes the styles of all Row. And I need only the right
Апостиль в Лос-Анджелесе без лишних нервов и бумажной волокиты
Основные этапы разработки сайта для стоматологической клиники
Продвижение своими сайтами как стратегия роста и независимости