title: jQuery to find parent label
body: <p>I have this HTML fragment:</p>
  
  <pre><code>&lt;div class="form-group"&gt;
    &lt;div class="col-sm-1"&gt;&lt;/div&gt;
    &lt;label for="allquestion4" class="col-sm-6 control-label label-red"&gt;Question&lt;/label&gt;
    &lt;div class="col-sm-1"&gt;&lt;/div&gt;
    &lt;div class="col-sm-3"&gt;
      &lt;select size="2" class="selectpicker" id="allquestion4" title="Choose"&gt;
        &lt;option value="0"&gt;No&lt;/option&gt;
        &lt;option value="1"&gt;Yes&lt;/option&gt;
      &lt;/select&gt;
    &lt;/div&gt;
    &lt;div class="col-sm-1"&gt;&lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Why is the label not being found by the following jQuery:</p>
  
  <pre><code>$(this).closest('label').hasClass('.label-red');
  </code></pre>
  
  <p>Where $(this) is the select picker.</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>Try <a href="https://jsfiddle.net/bigalnz/stezu0cr/4/" rel="nofollow noreferrer">this</a> fiddle.</p>