Ok so this should work :
At the top of index.php of your current theme
<?php
if ($_SERVER['HTTP_REFERER'] != "http://www.surfecsc.com/landing.php")
{
header("location: landing.php");
exit();
}
?>
Replace “landing.php” with the correct value in your case.
Your browser will redirect to your landing page if it doesn’t come right from this page.
But beware, HTTP_REFERER is set by the user agent. Not all user agents will set this, and some provide the ability to modify HTTP_REFERER as a feature. In short, it cannot really be trusted.
and you can remove all the session things in the landing page I told you in the first solution.
@kraignos
thank you i will try this. question – do i need to replace my current htaccess file?
Errr if it was the first time you tried to change something, no. Restore the default one.
update – i was told the way i had my permalinks set was the issue. when changed to /postname/
the original solution i was having the problem with now works.
thank you for those who responded and offered solutions.
I’ve got a similar need to the OP, but in my case would like to have a graphic for the landing page timed so that it appears for 2~3 seconds, then automatically jumps to the main site.
Suggestions?
(ideally I’d like it to fade to the main site, but probably impossible without Flash….)
Thank you….
hello @tracievh
i’m trying to do the exact same thing. have a temporary landing page but still allow users to visit the rest of the site with an enter site link. kind of like this… http://melaniefiona.com/
how were you able to do so. there are so many reponses above not sure which one worked and what the process was.