title: Check if div has a background image set
body: <p>I'm trying to check if a specific div has a background image URL set.</p>
  
  <p>Here's the structure without a background image:</p>
  
  <pre><code>&lt;div id="page-header"&gt;
    &lt;div class="bg"&gt;
      &lt;div class="bg-layer-upper-image" style=" background-image: url();"&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>And here's the structure with one set (they're dynamic):</p>
  
  <pre><code>&lt;div id="page-header"&gt;
    &lt;div class="bg"&gt;
      &lt;div class="bg-layer-upper-image" style=" background-image: url('https://example.com/images/background-1.jpeg');"&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>And here's my JQuery - it always thinks there's a background image though:</p>
  
  <pre><code>if ( $('#page-header').find('.bg-layer-upper-image').css('background-image') != 'url()' ) {
    alert('There is a background image');
  }
  </code></pre>
  
  <p>Any idea why that is?</p>