RE: [PHP] Tip for cookies
| From: | Don Read | Date: | Tue, 17 Apr 2001 23:16:32 +0000 |
| Subject: | RE: [PHP] Tip for cookies | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-49079@lists.php.net to get a copy of this message | ||
On 17-Apr-01 Pat Hanna wrote:
> I found out today after suffering from minor headaches and hair loss that if
> you have functions defined in and outside file name 'foo.php', and in those
> functions you use cookies, you must pass those cookies to the function
> called. I tried using a value from a cookie in a function and it never could
> access it unless I passed it. Funny
function my_func() {
global $cookie; // ?
if ($cookie == "thin mint")
call_girl_scout();
}
BTW, sometimes the hair does grow back.
--
Don Read dread@texas.net
-- It's always darkest before the dawn. So if you are going to
steal the neighbor's newspaper, that's the time to do it.