"); print ("One of the fields was left blank. Please put something in all fields.

"); print ("
"); email_form(); } elseif (ereg("([[:alnum:]\.\-]+)(\@[[:alnum:]\.\-]+\.+)", $email)) { $recipient = $to; $subject = $the_subject; $additional_headers = ("From: $email\n"); $body = ("Country: $subject\n Name: $name\nEmail: $email\n\nMessage:\n" . $message); if (mail($recipient, $the_subject, $body, $additional_headers)) { print ("
"); print ("The Mail was sent successfully to $recipient.

"); print ("

"); } else { print ("
"); print (" Something went wrong with the script! Please try again.
"); print ("

"); $send = "false"; email_form(); } } else { print ("
"); print ("That email address does not appear to be valid. Please try again.
"); print ("

"); $send = "false"; email_form(); } } else { print ("
"); print ("Select who you want to mail from the box below and fill out the form.
"); print ("

"); email_form(); } function email_form() { global $subject_array, $recipient_array, $this_script, $PHP_SELF; print ("
"); print ("
\n"); print ("\n"); print ("

\n"); print ("Name Surname:


\n"); print ("Your Email Address:
\n"); print ("

\n"); print ("Select Country
"); print ("

\n"); print ("Your Message:
\n"); print ("

\n"); print ("  \n"); print ("\n"); print ("
\n"); print ("
"); } ?>