You can remove the variable from PHP by doing unset($HTTP_COOKIE_VARS['file']); or unsert($_COOKIE['file']);
To remove the cookie from the clients machine, you must replace it with a cookie that has already expired, which will tell the browser to delete it. Like so:
setcookie("file", "", time() - 3600);
see this url for more info:
http://www.php.net/manual/en/features.cookies.php