Javascript API Is Working Fine On The Main Site, But Fails To Work On An External Server
This code can be used in conjuction with jQuery to embed a button on a page letting users share a link to my site.
or
<?php header('Access-Control-Allow-Origin: *'); ?>
(the wildcard is going to allow any domain to send requests to your host. I recommend replacing the asterisk with a specific domain that you will be running scripts on)
Also you need to send Origin header from ajax to the server
Origin: http://example.com/ajax.html
XMLHttpRequest cannot load filename.
You may like these posts
Post a Comment for "Javascript API Is Working Fine On The Main Site, But Fails To Work On An External Server"