personally, now PHP4 has all the session support builtin, i find it a lot easier than fiddling around with cookies by hand.
to use sessions, you just use the following lines at the start of every page you want to share variables...
session_start();
session_register("user_name");
session_register("another_thing");
etc...
(or the variable names can be combined in one call to session_register... session_register("user_name", "another_thing"))
and then use $user_name, $another_thing as normal. PHP takes care of all the cookie stuff brilliantly. the only thing to watch out for is if you are also passing variables around in other ways... if two names conflict, the winner will be decided by the info in your PHP setup - but this shouldn't be a problem if you name variables clearly.
hope it helps
dom
🙂