Why isn't this "if statement" working? : <p>I have built a weather app that works perfectly. I decided to add in icons that change with the weather id variable from an API which has been assigned. It works for the first id in the if statement, but when I add else if statements inside it don't work for the else if parts here is my code: </p>

<pre><code>       //weather icons check       
          if(weatherId=800){
             $('#type').css('background-image', 'url(http://publicdomainvectors.org/photos/weather-clear.png)');
          }
          else if(weatherId&gt;=801 &amp;&amp; weatherId&lt;=804){
              $('#type').css('background-image','url(http://publicdomainvectors.org/tn_img/stylized_basic_cloud.png)');
          }
          else if(weatherId&gt;=300 &amp;&amp; weatherId&lt;=531){
               $('#type').css('background-image','url(http://publicdomainvectors.org/tn_img/sivvus_weather_symbols_4.png)');
          }
</code></pre>

<p>am I missing something in this statement??? </p>
