A little problem with openweather api

when i get the data from the api it shows error 404 not found.but when i paste the same url’
in address bar i get a JSON response.Help please.
http://codepen.io/R_Ganesh/pen/WoGRYP

Hi

url:'api.openweathermap.org/data/2.5/weather?zip='+zipcode+','+country+'&APPID=529089e36675b3919f42423398a84037',

should be

url:'http://api.openweathermap.org/data/2.5/weather?zip='+zipcode+','+country+'&APPID=529089e36675b3919f42423398a84037',

I added http:// before the url. That should do it :slight_smile:

When you paste it into the browser, the browser is adding the http:// for you.

3 Likes

Thanks you so much for the quick reply and it worked,

no probs :slight_smile:

1 Like