View Full Version : Sending EMail in php

Active X
11-09-2007, 12:50 PM
Hi to all developers reading this thread .

I want to send EMail in php using mail() function .
I've installed php over IIS 7.0 (Windows vista) using php5isapi.dll .

When I want to send mail , I get this message :

Could not relay for SMTP agent someone@somehost.com (for example) , in Mail.php on line 9 .

Will be really thankful to your helps

11-09-2007, 01:55 PM
What does your code look like?

11-09-2007, 04:54 PM
Did you set your SMTP server settings in your php.ini?

Active X
11-12-2007, 01:58 PM
No , I've not edited mail addresses in php.ini .

I can do it on localhost but what if my website is uploaded to a registered domain ? Can I edit php.ini then ?

11-12-2007, 06:50 PM
More than likely your host has mail settings setup so you can send mail with mail(). You shouldn't need to change any settings(and you can't, unless you have root access) on your host.

Active X
11-13-2007, 09:06 AM
Thanks to all of you for help