I need a back button script that works for the new window.



Sep 2, 2019
Hello Everyone,

I need a script that makes LP Back Button activate once the new window (pop-under or pop-up) is open and the user can press on it so he/she directed to specific link,

I always use this script :

<script type="text/javascript" src="backfix.min.js"></script>
<script type="text/javascript">bajb_backdetect.OnBack = function(){window.history.back=function(){document.location='Your-URL'}}</script></body></html>

But when I tested it from the campaign link, I found the path as follows:

When the window open for the first time the back button is inactive, then when the user directed to the offer, He/she can go back to the LP again and then can press on the back button, then he/she can be directed to the specific link that I put in the link above.

What I need is a when the window open to the user as a new window (ex: popunder or popup according to the traffic), he or she can press on back button after press okay on the ENTER window, so he/she can be directed to another link.

Also this script path not working as I want:

! function () {
var t;
try {
for (t = 0; 10 > t; ++t) history.pushState({}, "", "#");
onpopstate =
To view the premium content in our affiliate marketing forum (including this awesome thread), you must first register and upgrade your account. Register today and become a part of our amazing community!