0

by placing this small snippet in chrome's console can hook to any ajax call in a page:

(function(open) {
  XMLHttpRequest.prototype.open = function(method, url, async) {
    console.log('ajax call!'); //do things
    open.call(this, method, url, async);
  };
})(XMLHttpRequest.prototype.open);

placing this in Gmail works but not in Google's new Inbox site. if ajax call are not made in this page - what other way do they use to get async data?

Sagiv Ofek
  • 25,190
  • 8
  • 60
  • 55

1 Answers1

1

They might sending XHR requests from internal iframe/s so overriding XMLHttpRequest in the console won't work.

Yshayy
  • 325
  • 2
  • 10