.val() not assigning return to new variable <p>After this zip will remain at 0 no matter what the value of "input" is. I suspect it has something to do with apiAddress not updating zip after the new value is assigned to zip. Can any one explain what is happening?</p> <pre><code>$(document).ready(function() { zip = 0; apiAddress = "api.openweathermap.org/data/2.5/weather?zip=" + zip; $("#submit").on("click", function() { zip = $("input").val(); $("#temperature").html(apiAddress); }); }); </code></pre>