I have a php based web application in which I want to redirect user to sub domain based on their country such as nz, au, in etc.
What is the best way to do that?
Htaccess?
PHP?
JavaScript?
How can I do with the above options?
Or you guys can suggest any other way as well!
2
Answers
Please! check this out:
geoPlugin
and there is more such way which is helpful.
Edit
Reference:
Code:
For more details:
PHP Geolocation Web Service
Something like this (Pseudo code!):