Earlier this month I wrote a quick PHP wrapper for Yahoo!’s GeoPlanet API. It’s a super useful service for querying geographical information about nearly any place on earth — addresses, landmarks, colloquial locations, etc. Or, as the official description says
GeoPlanet helps bridge the gap between the real and virtual worlds by providing an open, permanent, and intelligent infrastructure for geo-referencing data on the Internet.
There were already Perl, Python, and Ruby wrappers. I figured I’d throw PHP into the mix.
Pete Warden has already written some example code that uses the wrapper to emulate Twitter’s nearby location search.
You can download the source from GitHub. As usual, it’s licensed under the MIT License and free to use in any way you like.