i want users to be taken to the landingpage.php each time when they visit the site for the next 5 times they visit the site.
the existing code i previously had (which is down below) works like a charm but brings the landingpage.php only once.
<?php
session_start();
if(!isset($_SESSION['views']) || !$_SESSION['views'])
{
$_SESSION['views'] = 1;
header("location: /landingpage.php");
exit;
}
?>
here it goes in this code.
user types www.mydomain.com and get redirected to www.mydomain.com/landingpage.php where clicks on HOME (<a href="www.mydomain.com">) button and goes to www.mydomain.com
closes to browser, and next day user types www.mydomain.com and gets directed to www.mydomain.com
what i need is that users redirected to the /landingpage.php at least the first 5 times they visit the site.
P.S. i hope, i made more sense this time. this could be very strategic and useful to capture user emails, advertise promotional, recent news, info video, etc. user gets fully familiar with the site.