0

I have a code

$(document).ready(function(){

    $('.Designer').load('http://www.barsamservice.com/1.txt');

});

but , the text file not loaded .

but if i download text file and upload it in my server . Text file is loaded

How do I use Access-Control-Allow-Origin

Danin Na
  • 409
  • 1
  • 3
  • 13

1 Answers1

2

This is due to the Same Origin Policy. You can only get the information if the other server has a running service that is reading the text file and gives you the output on request.

ImreNagy
  • 511
  • 2
  • 10