Hi guys,
Anyone can help me set up a script that checks/places a cookie on a mobile visitor?
So what i want is if a user has cookie XX is redirected to page B, if doesn't have the cookie it's redirect to page A and cookie is place.
This way i would eventually remove duplicated visits.
Thanks!
What tracker do you use?
In
So when user already got tracked = has cookie you send him somewhere else.
Apart from that I can send you a PHP code for it when I am back on my PC.
Hey! thanks! I already use
Here is a very simple PHP code for it
<?php
if(isset($_COOKIE['yourcookie'])){
header("Location: https://pageB.com");
exit;
}
else{
setcookie("yourcookie",9999999999);
header("Location: https://pageA.com");
exit;
}
?>
<?php
if(isset($_COOKIE['yourcookie'])){
header("Location: https://pageB.com");
exit;
}
else{
setcookie("yourcookie",9999999999);
}
?>
Cool! This looks simple... thanks!
can i add another else, to check if cookie is in place (if so move to my offer). I guess BOT won't allow cookies so might be good to cut "none cookie" traffic