I need to produce a weather widget like on this site : -
Any help much appreciated!
Why don’t you use PHP Wheather.Weather is a PHP script to provide weather data for cities around the world.I think it will help you.
thanks for your input, ive written my own PHP script using Yahoo’s RSS weather service.
The only problem is, weather is returned by Yahoo’s location codes e.g. “UKXX1822”. But I want my users to search by location name e.g. “London” or post code.
Can anyone think of a way around this?
Is your code in terms of longitude and latitude?If so you can use Google Geocoder, which supports reverse geocoding returns address_components. You just need to pull out the component of the address tagged with locality and political if you just want the city name. If you want states as well they are tagged with administrative_area_level_1.
Heya, im not using lat / lng nope. In the end I used two tables, one with the codes & location names, and the other with postcodes. I used some clever joins to link the postcodes to the location codes - seems to work ok.
Thanks for your input much appreciated