1) There are compulsory to install and configure mail server on Localhost to use mail (); ?
2) I have installed WAMP 5 in my localhost machine any change in WAMP configuration file also need to use mail (); ?
3) POP3, MIME, etc also required ?
4) Any more information to complete this task please welcome?
5) Overall my aim is to use mail() in WAMP5 and it should be delivered. OK.
I read in the web page that :
The mail() function allows you to send emails directly from a script.
This function returns TRUE if the email was successfully accepted for delivery, otherwise it returns FALSE.
Syntax
mail(to,subject,message,headers,parameters)
Parameter Description
to Required. Specifies the receiver / receivers 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. Each line should be separated with a LF (\n). Lines should not exceed 70 characters.
Windows note: If a full stop is found on the beginning of a line in the message, it might be removed. To solve this problem, replace the full stop with a double dot:
QUOTE
<?php
$txt = str_replace("\n.", "\n..", $txt);
?>
Note: When sending an email, it must contain a From header. This can be set with this parameter or in the php.ini file.
parameters Optional. Specifies an additional parameter to the sendmail program (the one defined in the sendmail_path configuration setting). (i.e. this can be used to set the envelope sender address when using sendmail with the -f sendmail option)
Web page also have sample Example:
QUOTE
<?php
$to = "somebody@example.com, somebodyelse@example.com";
$subject = "HTML email";
$message = "
<html>
<head>
<title>HTML email</title>
</head>
<body>
<p>This email contains HTML Tags!</p>
<table>
<tr>
<th>Firstname</th>
<th>Lastname</th>
</tr>
<tr>
<td>John</td>
<td>Doe</td>
</tr>
</table>
</body>
</html>
";
// Always set content-type when sending HTML email
$headers = "MIME-Version: 1.0" . "\r\n";
$headers .= "Content-type:text/html;charset=iso-8859-1" . "\r\n";
// More headers
$headers .= 'From: <webmaster@example.com>' . "\r\n";
$headers .= 'Cc: myboss@example.com' . "\r\n";
mail($to,$subject,$message,$headers);
?>
I make changes as where needed but my mail is not delivered,
So please anybody could help how to we success in delivering mail from my local WAMP5 to On Internet.
Thanks

