mail() in XAMPP?

Problems with the Windows version of XAMPP, questions, comments, and anything related.

mail() in XAMPP?

Postby Basinator » 30. March 2012 08:07

Hi!
I am doing an internship at an IT company.

I want to send a mail with php mail() I tried both localhost and the SMTP of the company's mail provider (the smtp settings are working in outlook).
Settings
Code: Select all
[mail function]
; For Win32 only.
; http://php.net/smtp
SMTP = smtp.1und1.de

; http://php.net/smtp-port
smtp_port = 25
username =*****
password =*****


or:
Code: Select all
;SMTP = localhost
; http://php.net/smtp-port
;smtp_port = 25


PHP code:

Code: Select all
   mail($empfaenger, $betreff, $Message,$headers);
   mail("seec1[at]gmx.net", "Sexy Käse", "Hallo du geiles schnitzel", "From: seec1[at]gmx.net");

I dont get any errors messages anymore, so I guess it might be either connected to the company's firewall or the inability to connect to the SMTP.
Basinator
 
Posts: 2
Joined: 30. March 2012 07:53
Operating System: Win 7

Re: mail() in XAMPP?

Postby WilliL » 30. March 2012 18:47

you only need to configure your mailing system proper.

If you use sendmail - why do you use outlook parameters? sendmail can't "understand" them.
Code: Select all
;eg.
;you wrote SMTP = smtp.1und1.de
;sendmail expects
smtp_server=smtp.1und1.de

sendmail.ini ist very good commented.
Willi
WilliL
 
Posts: 660
Joined: 08. January 2010 10:54
Operating System: Win7Home Prem 64 SP1

Re: mail() in XAMPP?

Postby Basinator » 30. March 2012 19:31

Which parameters are you talking about? username, pw? WEll, I simple tried out since I wasnt able to get my mails through with localhost. However, as mentioned before, the firewall might be blocking mails sent from localhost.
Basinator
 
Posts: 2
Joined: 30. March 2012 07:53
Operating System: Win 7


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 187 guests