Tag Info

New answers tagged


So I guess the answer to this question is on the manner the other domain is responding to the request. Upon closer inspection of the reply of OSM server (e.g. http://b.tile.openstreetmap.org/6/56/29.png), the header is set to Access-Control-Allow-Origin:* thus there are no cross-origin issue encountered.


http://jsfiddle.net/a6pp9vwz/9/ working for me. Console log said "$ not defined". $ is a jQuery class, so you need a jQuery environment to enable AJAX requests. You can enable jQuery in JSFiddle in the "Frameworks & Extensions" tab.

Top 50 recent answers are included