Sending Email
Posted by: MooMan65 (---.ue.woosh.co.nz)
Date: July 05, 2007 03:12AM

Hey everyone! I'm developing a real estate site locally that requires emails to be sent in the form of market appraisals and related. I am trying to test the basic mail function but for some reason it does not appear to be sending any emails off. Currently this is my code:

$to = "mooman65@hotmail.com";
$from = "acuriousperson@homeowner.com";
$subject = "Subject";
$message = "Hi there!";

$headers = "From: $from\r\n";
$headers .= "Content-type: text/html\r\n";

mail($to, $subject, $message, $headers);

Is there anything special that I need to enable or something? Or set up? Cheers for any help you could provide! smiling smiley

Options: ReplyQuote
Re: Sending Email
Posted by: zlatan (---.192.208.65)
Date: July 05, 2007 10:45PM

well, first u need to have a mail server on your side. refer to php.ini [mail function]
; For Win32 only.
SMTP = localhost

; For Win32 only.
sendmail_from = me@localhost.com


usually for the SMTP you would put youremail@yourispprovider then you would be able to use the mail function properly. as long as your provider does not require secure exchange of the information via TLS you should be ok.

Options: ReplyQuote


Sorry, only registered users may post in this forum.