Check out "global" it allows you to make things "global" or at the top of your
file you could do a define with the cookie value in it an it would be accessbile
without passing the value to the function - this saves both time in typeing
and is faster since it doesn't have to copy the cookie value to a local variable
each time it is used in a function.

--Joe

On Tue, Apr 17, 2001 at 06:36:45PM -0400, 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
> --
> Patrick Hanna
> Database integration--E-commerce solutions
> The Wentworth Company


/* Joe Stump
 * Sr. PHP Developer 
 * http://www.Care2.com http://www.joestump.net http://gtk.php-coder.net
 */


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to