I'm trying to make a small snippet on Google Chrome (as a bookmark) so I can "alert" my remote ip adress, but it is not working as it gives me the following error :
XMLHttpRequest cannot load https://l2.io/ip.js?var=myip. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://stackoverflow.com' is therefore not allowed access.
var url = "https://l2.io/ip.js?var=myip" var httpRequest = new XMLHttpRequest() httpRequest.onreadystatechange = function (data) { // code } httpRequest.open('GET', url) httpRequest.send() alert(httpRequest["response"]) How can I get around this problem ?
