Trying to do something pretty basic here.
There’s a cookie, which is set as a user visits one of our affiliate pages, called AffiliateID. I would like to extract the ID from the cookie and put it in an empty form field to be passed on to another PHP doc which creates and sends an email to me. According to my temporary echo though, the cookie is not being read.
[code=php] <?
// Reads cookie:
$_COOKIE[‘AffiliateID’];
echo “Affiliate ID=”.$_COOKIE[‘AffiliateID’];
?>
<form name=”finance-app” method=”post” action=”finance-enqiry.php” onSubmit=”return process();”>
<input type=”hidden” value=”<? echo $_COOKIE[“AffiliateID”]?>” name=”affID” />
The cookie file is called “
Can anyone help? This is my first time working with PHP and cookies.