Send Email using WAMP
Posted by: JJJCR (58.185.170.---)
Date: November 19, 2012 11:34AM

Hi guys, I had installed WAMP on my local windows 7 machine on my network.

I had my email server hosted on linux but it is on a different subnet.

My question is how do I configure my WAMP server installed on a local windows 7 machine to send email?


Thank you for any input.

Options: ReplyQuote
Re: Send Email using WAMP
Posted by: stevenmartin99 (Moderator)
Date: November 19, 2012 04:32PM

you need a mail server that you can access..


just fill in the details in the php.ini

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Send Email using WAMP
Posted by: sTimulated (---.plus.com)
Date: December 09, 2012 09:33PM

I tried this but get this error..

Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\stimulatedgaming\Contact_Us.php on line 80

That says to me it's not recognising my smtp details?
Do I need to 'uncomment' any lines?
Do I need to enable any modules or extensions?

I change these 2 lines in the php.ini ....................

[mail function]
; For Win32 only.
; httx://php.net/smtp
SMTP = localhost
; httx://php.net/smtp-port
smtp_port = 25

; For Win32 only.
; [php.net]
sendmail_from = you@yourdomain

Maybe it's to do with authentication?
Although I tried adding my username and pass......



Edited 4 time(s). Last edit at 12/10/2012 01:52PM by sTimulated.

Options: ReplyQuote
Re: Send Email using WAMP
Posted by: scarabaeus (---.dhcp.gwnt.ga.charter.com)
Date: December 10, 2012 02:15PM

From that error message, I would surmize that you have not installed a mail server on localhost:25.
But from the information provided, that is just a guess.

As Steven and others have said many times on this fourm:

[forum.wampserver.com]

Wamp does not natively have a mail server, you need to provide a mail server for sendmail to connect to.

The mail server can be on the same machine as Wamp, in which case the 'localhost at port 25 would be appropriate.
Or it can be elsewhere on your lan, or the internet. (it could even be your ISP, if they allow relaying)
In which case the send mail config should include the IP address or hostname of the machine hosting the mail server.
Think of sendmail like an email client which only sends to the server. You set up sendmail like the email client you use for your normal email communciation.

HTH

regards...

Options: ReplyQuote
Re: Send Email using WAMP
Posted by: sTimulated (---.plus.com)
Date: December 10, 2012 02:34PM

thanks,that answers my question.

Options: ReplyQuote


Sorry, only registered users may post in this forum.