FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » sendmail from localhost is driving me crazy!
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
sendmail from localhost is driving me crazy! [message #184801] Mon, 03 February 2014 09:03 Go to previous message
shumit is currently offline  shumit
Messages: 1
Registered: February 2014
Karma:
Junior Member
I have followed the universally accepted methods for sending mail from gmail but I cannot yet send a single email. I am using wampserver.

My sendmail config is

smtp_server=smtp.gmail.com
smtp_port=465
smtp_ssl=SSL
default_domain=localhost
error_logfile=error.log

auth_username=myaccount(at)gmail(dot)com
auth_password=pwd
hostname=localhost



Pretty standard.

My Php.ini file now contains the following

sendmail_path = "c:\wamp\sendmail\sendmail.exe -t -i"

And yet I cannot send a mail. I had this working before I moved my PC from XP to Windows 8 so I really don't know what is wrong.I have tried every combination of port and SSL, turned off firewalls. Nothing.

I enabled “ssl_module” module in Apache server
and
enabled “php_openssl” and “php_sockets” extensions for PHP compiler.

But nothing is coming through. My PHP code is pretty simple

$to = 'shumit(at)gmail(dot)com';
$subject = 'Testing sendmail.exe';
$message = 'Hi, you just received an email using sendmail!';
$headers = 'From: tttt(at)gmail(dot)com' . "\r\n" .
'Reply-To: tttt(at)gmail(dot)com' . "\r\n" .
'MIME-Version: 1.0' . "\r\n" .
'Content-type: text/html; charset=iso-8859-1' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
if(mail($to, $subject, $message, $headers))
echo "Email sent. ";
else
echo "Email sending failed. ";


Any ideas?

thanks is advance
Shumit
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: RE: Seeeking Windows PHP IDE for USB Stick
Next Topic: login validation from 2 tables in same database
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Wed Nov 27 14:25:29 GMT 2024

Total time taken to generate the page: 0.04037 seconds