im trying to send a simple email using the mail() funtion but getting this error message every time:
Warning: mail() [function.mail]: "sendmail_from" not set in php.ini or custom "From:" header missing in c:\wamp\www\Mail\sendmail.php on line 3
i have sendmail_from in php.ini set to my own email address. i only have php set up locally on my pc, would this make a difference.? if not what else could be the problem?
mail() problem
Moderator: General Moderators
-
dannymc1983
- Forum Commoner
- Posts: 80
- Joined: Wed Feb 16, 2005 7:24 am
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
Yeah it's just the variable in the ini but I think feyd meant if it's not enabled.
Have you set up your smtp server since you're running on localhost unless you are hosting your own SMTP server. You'll need to set it up to the same as the one provided by your ISP otherwise. the bit in the ini that says
Also, depending upon the valoume of emails you are intending to send, alot of ISP's block you from sending so many in a set amount of time. Too many people wanting to spam people these days...

Have you set up your smtp server since you're running on localhost unless you are hosting your own SMTP server. You'll need to set it up to the same as the one provided by your ISP otherwise. the bit in the ini that says
right near the sendmail_from part.SMTP=*****
Also, depending upon the valoume of emails you are intending to send, alot of ISP's block you from sending so many in a set amount of time. Too many people wanting to spam people these days...
-
dannymc1983
- Forum Commoner
- Posts: 80
- Joined: Wed Feb 16, 2005 7:24 am
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
It should be the one in C:\Windows unless otherwise specified but to diuble check just run
on your local machine and somewhere near the top it tells you the ini file it is using...
Code: Select all
<?php
phpinfo();
?>