How: In console add hook into XMLHttpRequest
Code:
var rawOpen = XMLHttpRequest.prototype.open;
XMLHttpRequest.prototype.open = function() {
if (!this._hooked) {
this._hooked = true;
setupHook(this);
}
rawOpen.apply(this, arguments);
}
function setupHook(xhr) {
function getter() {
console.log('get responseText');
delete xhr.responseText;
var ret = xhr.responseText;
setup();
console.log('url : %s',xhr.responseURL);
console.log('ret : %s',ret);
return ret;
}
function setter(str) {
console.log('set responseText: %s', str);
}
function setup() {
Object.defineProperty(xhr, 'responseText', {
get: getter,
set: setter,
configurable: true
});
}
setup();
Source : http://stackoverflow.com/questions/16959359/intercept-xmlhttprequest-and-modify-responsetext
Fut Turkey so good page
回覆刪除Nice & Informative Blog !
回覆刪除Our team at QuickBooks Customer Service Number is ready to answer all your queries and questions through thick and thin.
Hey! What a wonderful blog. I loved your blog. QuickBooks is the best accounting software, however, it has lots of bugs like QuickBooks Error. To fix such issues, you can contact experts via QuickBooks Support Phone Number
回覆刪除