Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

122
Views
How to track all gif request that is happening on the website by JavaScript?

I checked the network tab on chrome dev tools, there are many request that being done, one of them is Facebook request that sending pixel data to Facebook. I want to track those request and get the data that is a GET request.

Is that possible to fetch those request url by JavaScript? Then how, I don't have any idea around it.

  <script>
    console.log('request tracking!');
    var origOpen = XMLHttpRequest.prototype.send;
    XMLHttpRequest.prototype.send = function() {
      console.log('request started!');
      this.addEventListener('load', function() {
        console.log('request completed!');
        console.log(this.responseURL);
      });
      origOpen.apply(this, arguments);
    };
  </script>

I tested this code, it returns some links but not all request that being done, at least get requests.

This is a sample get request I like to track https://www.facebook.com/tr/?id=245300970880426&ev=fb_page_view&dl=https%3A%2F%2Fgetmessiah.app%2Fdashboard&rl=&if=false&ts=1646638190415&sw=1600&sh=900&at=

Update It looks the Facebook request is gif, and till now I just fetched the list of xhr and fetch requsts.

enter image description here

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!