$url) {
deletecookie($id);
}
header("Location: $PHP_SELF");
} elseif(is_numeric($_GET["delete"])) {
deletecookie($id);
header("Location: $PHP_SELF");
} elseif(!empty($_GET["formfeedurl"])) {
addcookie($formfeedurl);
header("Location: $PHP_SELF");
} elseif ($cookiecount > 0) {
foreach($cookies as $id=>$url) {
echo ""; // For debugging, or something.
?>
Delete All Cookies
Please refresh the page
$value) {
if (ereg("^FeedCookie-([0-9]{1,2})$",$name,$regs)) {
$id = (int)$regs[1];
$cookies[$id] = $value;
}
}
$cookiecount = count($cookies);
}
function addcookie($value) {
global $cookies;
for ($i=0; $i<100; $i++) {
if (!isset($cookies[$i])) {
$id = $i;
break;
}
}
if (!isset($id)) {
echo "No ID.";
return 0;
}
setcookie("FeedCookie-$id",$value,time()+3600);
return 1;
}
function deletecookie($id) {
global $cookies;
if (isset($cookies[$id])) {
setcookie("FeedCookie-$id","",time()-3600);
return 1;
} else {
return 0;
}
}
?>