Make the javascript don't run in specific countries -
i have javascript redirect script. redirects when country us.
<script> function determinecountry(data){ switch(data.address.country_code){ case "us" : document.location.href = "http://xxxxxxxx.biz/theme.php"; break; } } </script> <script type="text/javascript" src="http://api.wipmania.com/jsonp?callback=determinecountry"></script>
now want reverse of this. don't run script when country us.
thanks in advance
just break
if country 'us'. change document.location.href
in default
switch
section.
function determinecountry(data){ switch(data.address.country_code){ case "us" : break; default: document.location.href = "http://xxxxxxxx.biz/theme.php"; } }
Comments
Post a Comment