Syntax: mail(to, subject, message, headers, parameters);
| to | Required. Specifies the receiver / receivers (semicolon delimited) of the email |
| subject | Required. Specifies the subject of the email. Note: This parameter cannot contain any newline characters |
| message | Required. Defines the message to be sent. Note: |
| headers | Optional. Specifies additional headers, like From, Cc, and Bcc. The additional headers should be separated with a CRLF (\r\n) |
| parameters | Optional. Specifies an additional parameter to the sendmail program |
For Example:
$to= $addy;
$subject ="My mailing thingy";
$headers = "From: me@myaddy.com";
$message ="This is my message\n\rNOTE: that I am using newline and return code as the headers do not specify text/html.";
mail ($to,$subject,$message,$headers);
If you use this last method, then the message MUST be in html code, not Unix style text code. Therefore use <p> for paragraphp spacing not \n\r