PDA

View Full Version : multiple pages on the same site


tommon
4th August 2011, 05:58 PM
Hi,

I'm working on a site, but this one has more pages. (niche tgp)

my question is: Are the in.php code's on the sub pages such as index.php or is this a different code.

THx

ICEFIRE
5th August 2011, 07:13 PM
You should use this include code on multipage sites:


$cookietime=300;
$referer=$_SERVER["HTTP_REFERER"];
if($_COOKIE["overkill_in"]<time()-$cookietime){
setcookie("overkill_in", time(), time()+($cookietime*1));
include ("in.php");
}


It will just work as the usual include, but will skip including in.php when jumping from one page to another relatively fast. This also prevents lots of false positives when detecting bots on such kind of sites.