Hello, I have the following:
if (subject == '---') { if(!$('label[for="Subject",class="Error"]').length) { $('#Subject').parent().after('<label for="Subject" generated="true" class="Error">Required field</label>'); } } I need to check if a label with for="Subject" and class="Error" exists: if(!$('label[for="Subject",class="Error"]').length) This is not working. What am I doing wrong? Thanks, Miguel