Menu
Umm.. hi.
I’m trying to make something that will change a variable ($variable) set in a php file (other.php) based on a match of keywords from the refferer (index.php?a=X) from which the guest came to the page.
For example, I have this index.php?a=one, and index.php?a=two. Each of them, when clicked will change the location.href to ‘other.php’, and on ‘other.php’ I have this:
echo ‘<a href=”index.php?a=’.$variable.'”>clicky</a>’;
How exactly can I set $variable to be either ‘one’ or ‘two’ based on what referrer I used to go to other.php ? :-/
(maybe there’s a way simpler solution and I’m terribly blind)