Hello i am trying to do GET through ajax here is what the error we are getting
Failed to load resource: Origin http://www.kashikart.com is not allowed by Access-Control-Allow-Origin.
XMLHttpRequest cannot load http://recharge.kashikart.com/api/recharge.php?uid=6b687274&pin=312556cbe3&number=7869386777&operator=1&circle=14&amount=10&usertx=foduu&format=JSON&version=4. Origin http://www.kashikart.com is not allowed by Access-Control-Allow-Origin.
We are just trying to do a normal ajax.
From main domain to sub-domain. But it seems like there is some issue with this. We use these two header on the top of our file from where the ajax request is passing in PHP. Here is how its look like:
<?php
header("Access-Control-Allow-Origin: *");
header("Origin: http://www.kashikart.com");
?>
I try to put the header in the .htaccess file as well. But didn't work.
Why its not allowing to call a request on on sub-domain? Suggest will be highly appreciate.
Thank you! (advance)