Re[2]: Generating weather maps
Brought to you by:
iridium
From: Jonas K. <me...@j0...> - 2004-03-04 11:20:33
|
Hello, > A simple workaround for the "it's not fast" issue would be to schedule > (eg cron) the map generation rather than recalculating it for each Page > View. Yes, this would be really useful. I already use a simple sort of caching, that is generating the map on the first request and storing it. Every other request in the next half hour gets the cached version of the map. Image generation itself is quite fast, getting all METARs takes a lot of time. So perhaps scheduling the METAR fetch might be sufficient. Another problem is that I have to fetch the METARs twice - one time in the map-generating script, the other time in the HTML-page to display the onMouseOver-Information for every station. Even with the built-in caching of phpWeather, I still have to query my database two times. Has anybody got an Idea how to solve this? > One simple thing I'd always thought would look nice was a worldmap with > every METAR station pinpointed. ImageMap to select a country, then show > (for example) your country weather map, and image-map to get detailed > METAR report. Nice idea. World map generation can also be done with the script I use. We also need positions for every country, so it would even be possible to generate the ImageMap to select a country dynamically. Cu Jonas |