Builder.com has a new tutorial posted today about the use of the PEAR Net_GeoIP package to help with the geo-location of the visitors to your website.
Ever wondered how sites like Google and Yahoo! always seem to know which country you're in, and automatically redirect you to the most appropriate country sub-site? Or how some Web sites display advertisements perfectly targeted to your city or region? Well, it isn't magic -- these sites are simply mapping your IP address to a geographical database to identify your location, and then using this information to send you precisely-targeted data.
They work through the steps to get it up and working - the installation, a few basic code examples to show how to use it, and a full example of how to target different areas with different kinds of ads (geographically-targeted advertising).