How can I send mail from my site using SMTP outgoing mail server. I tried and checked may way but not achive any positive result.
Here is my mail server detail-
SmtpPass="password@123"; // assume this is the password
Can any body help me out in this with some sort of code.
I am trying one example I found on net -Example Site But this also not works.
Thank you in advance.
is this Windows or Linux based server?
Thank you Squidge for consideration my problem I am using PHP
Sorry i miss read. you would use the "mail" function:
That should help.
I hadnt seen the link you posted.
I have never had to do this that way.
The SMTP would be configured by your hosting, so just use the "mail" function from my link to PHP.net
$to = 'email@example.com';
$subject = 'the subject';
$message = 'hello';
$headers = 'From: firstname.lastname@example.org' . "\r\n" .
'Reply-To: email@example.com' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail($to, $subject, $message, $headers);
OK let me try your code
Thatis an example from PHP.net - this is not from me.t
$to = '' // email address where to send
$subject = '' // Subject matter captured from form
$message = '' // captured from form
mail($to, $subject, $message); // Sends the message
Thank you Squidge really a silly mistake gives lots of pain I was not passing the value of email from form page. Any ways thankyou for extended support.
Thank you very much
not a problem, glad it is resolved :)