35.gif

Search (advanced search)
Use this Search form before posting, asking or make a new thread.
Tips: Use Quotation mark to search words (eg. "How To Make Money Online")

07-15-2013, 08:04 AM
Post: #1
[REQ]Geoip redirect based on City
hey there!
need a litlle help with geoip redir code to redirect certain cities to diff links, can be in js or php
i was testing this:
<script src="//j.maxmind.com/app/geoip.js" charset="ISO-8859-1" type="text/javascript"></script>
<script>
if (city == 'city1') {
window['location'] = 'http://google.com';
};
if (city == 'city2') {
window['location'] = 'http://google.com';
};
if (city == 'city3') {
window['location'] = 'http://google.com';
};
</script>

but this is only for registered users (401 error - need domain authorization)
I've downloaded their city database but i have no idea how to connect it to the script to make it work




19.gif