Tuesday, 1 October 2013

Why is "if" not working?

Why is "if" not working?

my $trefer = $ENV{HTTP_REFERER};
my $gk1 = substr($trefer, -4);
my $gk2 = ".swf";
my $antigk = $gk1;
if ($gk1 = $gk2) {
$antigk = $trefer;
}
else
{
$antigk = $link;
}
so whats wrong with this code? if is not working for example referal is
site.com/2nujroj49lni, it should show me the $link but instead it shows me
the $refer
why ? i dont get it
as long as it is not .swf i should get link not the referal i searched
over the internet and it looks legit . no errors as far as i can see but
still not working

No comments:

Post a Comment