TT#159000 fix 403 error when loading call details

Change-Id: I10f4f597d60bec7751417219a8e402dfd5bce4b8
mr10.3
Rene Krenn 4 years ago
parent c3ae96a2bd
commit dcce2b83a1

@ -1,4 +1,4 @@
function background(uri,q,callback) {
function background(uri,q,callback,method) {
var xmlHttpReq = false;
//alert(uri);
//alert(q);
@ -10,7 +10,10 @@ function background(uri,q,callback) {
xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
}
xmlHttpReq.open('POST', uri, true);
if (method == null) {
method = 'POST';
}
xmlHttpReq.open(method, uri, true);
xmlHttpReq.setRequestHeader('Content-Type','application/x-www-form-urlencoded');
if(callback)
xmlHttpReq.onreadystatechange = function(){
@ -28,7 +31,7 @@ function background(uri,q,callback) {
// Background fetches a page into the specified element
function fetch_into(div, uri, q, callback) {
function fetch_into(div, uri, q, callback, method) {
var xmlHttpReq = false;
//alert(uri);
//alert(q);
@ -49,8 +52,10 @@ function fetch_into(div, uri, q, callback) {
xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
}
//var fd = new FormData();
xmlHttpReq.open('POST', uri, true);
// xmlHttpReq.open('GET', uri, true);
if (method == null) {
method = 'POST';
}
xmlHttpReq.open(method, uri, true);
xmlHttpReq.setRequestHeader('Content-Type','application/x-www-form-urlencoded');
xmlHttpReq.onreadystatechange = function() {
if (xmlHttpReq.readyState == 4) {

@ -23,7 +23,8 @@ function showCallDetails(callId){
}).css('display','block').find($('.mod_close')).click(function(event) {
$('#'+divId).css('display','none');
});
}
},
'GET'
);
}
</script>

Loading…
Cancel
Save