Cannot get the code below to send the email to myself...
Trying to get a web based notification process for server outages...
ANy help would be great thanks....
--Craig
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Untitled</title>
</head>
<body>
<FORM>
<input type="radio" name="planned" value="form">planned<br>
<input type="radio" name="short" value="form">short
<input type="text" name="to" value="test to" size="100" maxlength="200">
<input type="text" name="from" value="test from" size="100" maxlength="200">
<input type="text" name="subject" value="test subject" size="100"
maxlength="200">
<input type="text" name="message" value="test message" size="100"
maxlength="200">
<input type="submit">
</FORM>
<?php
$headers = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers .= "From: $from\r\n";
$headers .= "Cc: craig.dennstedt@usa.xerox.com\r\n";
$headers .= "Bcc: \r\n";
function mymail() {
mail($to, $subject, $message, $headers);
//this works since to, subject, and message, are defined above in the form, and those are the names of the inputs.
}
?>
</body>
</html>