Extract a parameter from the json array.
Below the json string:
If I want to obtain the weather "description" I have to use array method on the previous string like this:
Below the json string:
{"coord":{"lon":18.17,"lat":40.36},"weather":[{"id":801,"main":"Clouds","description":"few clouds","icon":"02d"}],"base":"stations","main":{"temp":299.93,"pressure":1013,"humidity":69,"temp_min":299.15,"temp_max":301.15},"visibility":10000,"wind":{"speed":8.7,"deg":120},"clouds":{"all":20},"dt":1504862100,"sys":{"type":1,"id":5749,"message":0.0227,"country":"IT","sunrise":1504844509,"sunset":1504890427},"id":6542124,"name":"Lecce","cod":200}
If I want to obtain the weather "description" I have to use array method on the previous string like this:
Extraction of the weather descprition from the json array. |
No comments:
Post a Comment