By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,664 Members | 1,656 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,664 IT Pros & Developers. It's quick & easy.

Why am I not able to receive email on mydomain.com when I am able to send emails?

kamill
P: 71
Dear Friends,

I am using a php mail function, with this script i am sending mail to customer of my client. Script id doing well with other domain but with same domain emails script is unable to send mail.

example:

my domain name where i am running script is www.example.com
and i have two email ids as xyz@example.com and xyz@abc.com then i am able to receive email at xyz@abc.com but not able to receive mail at xyz@example.com.

[PHP]<?php
$from='test@example.com';
$headers = "From: $from";
$headers = "Content-type: text/html; charset=iso-8859-1\r\n"; $to1='xyz@example.com';
$to2='xyz@abc.com';
$subject='Test Subject';
$msg='Test Message';
mail($to1, $subject, $msg, "From:$from\n".$headers);
mail($to2, $subject, $msg, "From:$from\n".$headers);
?>
[/PHP]


I have got stuck with it. Please help me.
Oct 17 '08 #1
Share this Question
Share on Google+
1 Reply


dlite922
Expert 100+
P: 1,584
This may not be a PHP problem but your mail server.

telnet to your mail server on port 25 (SMTP) and send an email through the command line.

check Google for SMTP commands and examples of how to do that.



Dan
Nov 1 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.