недавно кому-то помогал с ним.
поправил немного
Код:
<?
if ($_POST['remove_url']=="")
{
echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Stop Spam Service</title>
</head>
<body>
<form name="form1" method="post" action="" >
<p>Please, type URL address of you resource here. It will be immediately removed from our list.</p>
<p>
<input type="text" name="remove_url" size="70" value="http://">
<input type="submit" name="Submit" value="Remove">
</p>
</form>
</body>
</html>
';
}
else
{
$t=parse_url($_POST['remove_url']);
$fp = fopen('urls.txt', 'a+');
fwrite($fp, str_replace('www.', '', $t['host'])."\n");
fclose($fp);
echo ("Thanks! You'll no longer receive messages with advertising from us!");
}
?>