mail does not send to all domain names

the mail() function

Moderators: macek, egami, gesf

radd
New php-forum User
New php-forum User
Posts: 4
Joined: Thu Jun 23, 2011 2:39 am

mail does not send to all domain names

Postby radd » Thu Jun 23, 2011 2:50 am

I use a very basic mail(); function that is not working on all domain names.
Such as, If the $to is set to "adam@agencemoon.com" everything works fine; but if I change it to: "adam@agence-moon.com" it stops sending emails.

Does it have something to do with the "-" in the domain name?

Even if the if(mail("adam@agence-moon.com",".... ...)) {} returns TRUE the email is not being received.
This is the phpinfo() page: http://www.agence-moon.fr/squelettes/test.php

User avatar
egami
php-forum GURU
php-forum GURU
Posts: 2196
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Re: mail does not send to all domain names

Postby egami » Thu Jun 23, 2011 4:52 am

Do you have access to a shell ?

radd
New php-forum User
New php-forum User
Posts: 4
Joined: Thu Jun 23, 2011 2:39 am

Re: mail does not send to all domain names

Postby radd » Thu Jun 23, 2011 4:56 am

I don't at this very moment, but I can ask if needed.
Why?

User avatar
egami
php-forum GURU
php-forum GURU
Posts: 2196
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Re: mail does not send to all domain names

Postby egami » Thu Jun 23, 2011 5:32 am

if you can send mail from the shell.. ie..


telnet somedomain.com 25
HELO somethingelse.com
mail from: me@mydomain.com
rcpt to: this@address.com

and see what the error code says.

radd
New php-forum User
New php-forum User
Posts: 4
Joined: Thu Jun 23, 2011 2:39 am

Re: mail does not send to all domain names

Postby radd » Fri Jun 24, 2011 8:47 am

I get a "telnet: command not found".
what are your commands doing? don't understand them...

User avatar
egami
php-forum GURU
php-forum GURU
Posts: 2196
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Re: mail does not send to all domain names

Postby egami » Fri Jun 24, 2011 8:55 am

they are SMTP commands.

radd
New php-forum User
New php-forum User
Posts: 4
Joined: Thu Jun 23, 2011 2:39 am

Re: mail does not send to all domain names

Postby radd » Sat Jun 25, 2011 4:33 am

ok, I can't use them...
do you have any other ideas?


Return to “PHP coding => Mail”

Who is online

Users browsing this forum: No registered users and 1 guest