Home > Paid Traffic Sources > Mobile

Back button loop (7)


01-18-2017 02:25 PM #1 orisin1 (Member)
Back button loop

Hey guys
does anyone have a script for a back button that keeps redirecting to my own offers landers so the user "can't" escape my offer by clicking the back button?


01-18-2017 04:46 PM #2 globejohan (AMC Alumnus)

<html>
<head>




<script type="text/javascript">
<!--
function Redirect() {
window.location="trackink click url ";
}

document.write("You will be redirected to main page in 1 sec.");
setTimeout('Redirect()', 50);
//-->
</script>
<script type="text/javascript">! function (){var t;try{for (t=0; 10 > t; ++t) history.pushState({}, "", "#");onpopstate=function (t){t.state && location.replace("your url for campaign ")}}catch (o){}}();</script>

</head>


<body>
</body>
</html>


01-19-2017 12:09 AM #3 aloeveraa1491 (Member)

<script type="text/javascript">
! function() {
var t;
try {
for (t = 0; 10 > t; ++t) history.pushState({}, "", "#");
onpopstate = function(t) {
t.state && location.replace("ENTERYOURURL here")
}
} catch (o) {}
}();
</script>


01-19-2017 12:24 AM #4 jabula (Member)

Please tell me what URL goes here "trackink click url ";
and I assume my offer goes ("your url for campaign ")


01-19-2017 07:21 AM #5 globejohan (AMC Alumnus)

if you have Voluum , you put use the "Click URL". But that part is not needed Jabula.


01-19-2017 02:35 PM #6 jabula (Member)

Quote Originally Posted by globejohan View Post
if you have Voluum , you put use the "Click URL". But that part is not needed Jabula.
Can you please post the script without that. I'm not script save, sorry. I want to give it to my programmer. I use iMobiTrax.
Tack så mycket


01-19-2017 03:44 PM #7 floridaim (Member)

<script type="text/javascript">
(function(window, location) {
history.replaceState(null, document.title, location.pathname+"#!/backbutton");
history.pushState(null, document.title, location.pathname);
window.addEventListener("popstate", function() {
if(location.hash === "#!/backbutton") {
history.replaceState(null, document.title, location.pathname);
setTimeout(function(){
location.replace("http://CAMPAIGN-URL.com/");
},0);
}
}, false);
}(window, location));
</script>


Home > Paid Traffic Sources > Mobile