Web Programming Week 9 Old Dominion University Department of Computer Science CS 418/518 Fall 2010 Martin Klein 10/26/10
Sending PHP syntax: mail($to, $subject, $message, $headers); e.g. <?php "My status line", "If I could only think of a msg I would put it here..."); echo "congrats, your was sent"; ?> (see firstmail.php, ch10)
Sending $to = $subject = "My subject line"; $message = " If I could only "; $message.= " think "; $message.= " of a msg "; $message.= " I would put it here. "; $headers = "MIME-Version: 1.0\r\n"; $headers.= "Content-type: text/html; charset=iso \r\n"; $headers.= "Content-Transfer-Encoding: 7bit\r\n"; mail($to, $subject, $message, $headers); (see secondmail.php, ch10)
From Mon Aug 16 09:33: Return-Path: Received: from mail.cs.odu.edu (darkisland.csnet.cs.odu.edu [ ]) by unixmail.cs.odu.edu (8.14.2/8.14.2) with ESMTP id o7GDXuSY (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NOT)for Mon, 16 Aug :33: (EDT) … MIME-Version: 1.0 … Subject: was hacked, I apologize it is fixed now. From: john doe To: Martin Klein Content-Type: multipart/alternative; boundary="001485f626f00069b6048df0e27f“ … f626f00069b6048df0e27f Content-Type: text/plain; charset="ISO " In case a message with a link was sent from me my was corrupted and sent out to my inbox. I have fixed the account and apologize for the inconvenience. John -- John M. Doe f626f00069b6048df0e27f Content-Type: text/html; charset="ISO " Content-Transfer-Encoding: quoted-printable In case a message with a link was sent from me my was corrupted and sent out to my inbox. I have fixed the account and apologize for the in convenience. =A0 John -- John M. Doe f626f00069b6048df0e27f-- Trailing -- indicate end of msg!