Thanks a lot Bear.
Here is another question.
Now i want to display a particular content to only a particular geographic area.
How do I find to which geographic a particular ip address belongs and display content only to those ip addresses?
http://www.ip2location.com is what I use althought they are now charging for their product but it works great. Basically you will need a database that has the IP ranges in it and they will probably need converted to hex and then you can run a query on the database to come up with your country code. I think I still have the older version they were giving out for free of IP2LOCATION shoot me a PM if you are interested.