title: Jquery once two options have been selected from select drop down list run code
body: <p>I have 2 select drop down menus. I want to to add a class once a option has been selected from both menus.</p>
  
  <pre><code>    $('#size').change(function(){ 
          if ($(this).val() &gt; 0 )  {
                $('#pizza').addClass('pizzaImage');
           }  
  
      });
  
      $('#crust').change(function(){ 
          if ($(this).val() &gt; 0 ) {
                $('#pizza').addClass('pizzaImage');
           }  
  
  
      });
  </code></pre>
  
  <p>This is my code so far, it works when I select an option from one. Basically I want to put these together I just don't know the syntax to do so. I also tried this but no results.</p>
  
  <pre><code>var size = $('#size')
  var crust = $('#crust')
  
  function image () {
    if ((crust).val &gt; 0 &amp;&amp; (size).val &gt; 0) {
      $('#pizza').addClass('pizzaImage');
    }
  }
  </code></pre>