i want to only allow website visitors from australia. has anyone done this before?
3 Answers
Try a service such as http://www.maxmind.com/ or http://hostip.info/
They can tell you where a user is located.
to be honest I have tried this, and it has never been a good idea. Even with a paid maxmind database I have had verified locals not being able to access the site. Several reasons come to mind, they maybe using a secure proxy to filter content or whatever. If you are doing this for a limited set of visitors (like employees of a company) or to reduce possibility of attacks from outside source then yes its a workable solution. In all cases, for production WWW I have had to eventually remove the country specific filters.