Created
March 21, 2022 18:18
-
-
Save fellypsantos/e26cb86ec40c9fcbcf1104197dded813 to your computer and use it in GitHub Desktop.
Script to intercept XMLHttpRequest calls made by some page.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Intercept XMLHttpRequests */ | |
(function(open) { | |
XMLHttpRequest.prototype.open = function() { | |
this.addEventListener("readystatechange", function() { | |
console.log("readyState: "+this.readyState); | |
}, false); | |
open.apply(this, arguments); | |
}; | |
})(XMLHttpRequest.prototype.open); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment