0

Hi,

I'm been looking online for sometime now and haven't really found anything that helped. Bascially my question is: Is there anything else I need to add to my php.ini file or on my Exchange server to allow me to recieve email since I'm not getting email currently from my form?

Information -----------
I have a Windows 2003 Server with IIS6 installed along with PHP. I have a contact form located on this server and when submitted, it goes to a PHP script (located in same directory) which sends the form information to my email address. Form is a basic one that just has a Question box.

Our email server is a Windows 2003 Server with MS Exchange 2007 running on it. Both of these servers are in the same domain and can ping each other with no problem. So from my reading, it sounds like the php.ini file would somehow talk to the Exchange server in order to submit the information to my email address.

PHP.ini Information ---------------
SMTP = mail.ourdomain.com
smtp_port = 25
sendmail_from = me@ourdomain.com

I found a php script online that tests if you can receive mail or not and once I generated the page, it said that mail could not be delivered.

<?php
$to = "me@ourdomain.com";
$subject = "Hi!";
$body = "Hi,\n\nHow are you?";
if (mail($to, $subject, $body)) {
  echo("<p>Message successfully sent!</p>");
 } else {
  echo("<p>Message delivery failed...</p>");
 }
?>

So from that, it obviously is that it can't send email. Anybody have suggestions that I can try.

3
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by pritaeas
0

Hey.

I can't really see any reason why that wouldn't work.
The mail() function is always a bit hard to work with tho.

Try something like PHPMailer and see if you that works any better. You can set the SMTP info directly in the code and get it to output the SMTP dialog, so it is a lot easier to debug.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.