so i want this code work like when user clik link it
check if it's allready click if not it write $user file
$advertise code and jump page continue.php if user
have click link it jump warnign.php
code works fine when user clicks first time it creates
($user).txt file and add $advertise code
<?php
$advertise = $HTTP_GET_VARS['A'];
$user = $HTTP_GET_VARS['I'].".txt";
$setok = "0";
if (file_exists($user))
{
$fp = fopen($user, "r"
echo "File : $user<br>";
while ($line = fgets($fp,255))
{
if (stristr($line, $advertise))
{
$setok = "1";
echo $line;
}
}
fclose($fp);
}
else
{
$fp = fopen ($user, "aw"
fputs($fp, $advertise."\n"
fclose($fp);
}
if ($setok == '0'){header("LOCATION: continue.php"}
elseif ($setok == '1'){header("LOCATION: warnign.php"}
?>
check if it's allready click if not it write $user file
$advertise code and jump page continue.php if user
have click link it jump warnign.php
code works fine when user clicks first time it creates
($user).txt file and add $advertise code
<?php
$advertise = $HTTP_GET_VARS['A'];
$user = $HTTP_GET_VARS['I'].".txt";
$setok = "0";
if (file_exists($user))
{
$fp = fopen($user, "r"
echo "File : $user<br>";
while ($line = fgets($fp,255))
{
if (stristr($line, $advertise))
{
$setok = "1";
echo $line;
}
}
fclose($fp);
}
else
{
$fp = fopen ($user, "aw"
fputs($fp, $advertise."\n"
fclose($fp);
}
if ($setok == '0'){header("LOCATION: continue.php"}
elseif ($setok == '1'){header("LOCATION: warnign.php"}
?>