Can't Send Email to Anyone but Myself

Status
Not open for further replies.

DonQ

New Member
Messages
2
Reaction score
0
Points
0
Hey all,
I've been trying to send emails through php with the mail() function. The php thinks it is being sent correctly but I am not receiving it. I tried sending email through the c-panel email UI and I also didn't receive it. But in both cases if I send an email to myself on my mail server then I can receive it. Does anyone know how I can get it to successfully send to other email addresses (such as gmail). I have a free account.
Thanks everyone,
DonQ
 

essellar

Community Advocate
Community Support
Messages
3,295
Reaction score
227
Points
63
What code, exactly, are you using? Are you trying to set the From header to any value that doesn't belong to your account?
 

DonQ

New Member
Messages
2
Reaction score
0
Points
0
What code, exactly, are you using? Are you trying to set the From header to any value that doesn't belong to your account?

The code I am using:
Code:
function testMail(){
    $to      = "myEmailAddress@gmail.com";
    //echo($to);
    $subject = '';
    $message = 'Test';
    $headers = 'From: validEmail@xcat.x10.mx' . "\r\n" .
                'Reply-To: validEmail@xcat.x10.mx' . "\r\n" .
                'X-Mailer: PHP/' . phpversion();


    if (mail($to, $subject, $message, $headers)) {
        echo("</br> sent </br>");
    }else{
       echo("</br> not sent </br>");
    }
}
testMail();

In my email accounts section of my C-panel, validEmail@xcat.x10.mx is listed there. The reason I didn't think this was the issue was because I used the built in email client in c-panel to send out an email which reacted in the same way (not getting received).
Thanks
 

kvenn

New Member
Messages
1
Reaction score
0
Points
0
I too am having this problem (since the first post was actually me because I forgot my password and just remembered it). I've read a bit about smpt but I don't know if that's a different thing or if that is already included in the php mail function.
Any help would be much appreciated.

Edit:
My error_log files isn't logging any errors and php tells me mail() is working. I haven't found any errors, my emails simply are not received by anyone but myself (my c-panel email). I can also send emails to my other email accounts on my c-panel.
 
Last edited:

rob8829

New Member
Messages
1
Reaction score
1
Points
0
I have tried sending an email through a valid verified php script that I have used on a multitude of other sites which will not send out going email from my site to the email address specified, the php mail routine returns true and there are no errors in the error logs on the site for any of the emails I have attempted to send through the script.

I have also tried to send an email through the webmail service and do not receive this message on any email account I attempt to send to.
So, I sent an email from gmail and yahoo to my webmail account and have received those on webmail.
However, when I reply from the webmail to the gmail or yahoo emails I received I do not receive the reply in my gmail or yahoo accounts.

I have also tried setting up my email address as being @myparked domain as well as $mysubdomain and get the same result either way.

I am assuming the email system is working fine since I can receive mail from various other sites and that the x10hosting domains and or ip addresses are blocked by yahoo and gmail would be nice to have confirmation of my assumption though and any suggestions for a workaround before I have to attempt to find another free host that offers a similar hosting package.

Also, are the x10hosting domains and/or ip addresses blocked by paypal, I have an ipnlistener as well as a pdt return page that work with other sites I have developed and they are not able to connect to either the live site or sandbox from my site hosted here.
 
Status
Not open for further replies.
Top