0
I have this Input that is generating via Knockoutjs:
<input type="text" class="req" placeholder="" data-bind="value:Request" />
But I have to check if it is empty and if I am applying a specific css: As it can be created several equal fields, I can only apply in the first field my validation.
My Javascript:
if ($(".req").val() == "") {
$(".req").addClass(validationClassErrosType.input)
}
validationCheckImage($("#req"), $("#req").parent());
The image of the input:
Well he always takes the first class. how could he do this via Avascript?
Now make it work. Thank you!
– Bruno H.