Hi to all...
i am struck with jsonp. My problem is when i am calling ajax method jquery its not getting in callback method.
For example:
i) i am calling ajax method from 'A' website to 'B' website.
ii) And again calling ajax method from From 'B' website to 'C' website.
But i am getting the values in callback methods.
if i call the ajax method from From 'B' website to 'C' website. i am getting the result in callback method.
A website method
<script type="text/javascript">
$("#form1").ready(function () {
$.ajax({
type: 'GET',
callback: 'callbback_fn',
contentType: "application/json",
dataType: 'jsonp'
})
});
</script>
<script type="text/javascript">
function callbback_fn() {
var json = arguments[0];
var data = '?A=' + json.CustomerCode + '&B=' + json.Flag;
window.location.href = 'MerchantCeckOutPage.aspx' + data;
}
</script>
B website ajax method
function callback_fn() {
if (arguments.length > 1) {
if (arguments[0] == true) {
}
}}
Please can anyone help me regarding this issue.