You are invited to Log in or Register a free Frihost Account!

Google domain applications issue.

Hi! I have pointed my domain and all its' possible subdomains to servers with the exceptions of and In addition, I pointed my MX records to Googles' servers. My Joomla! based website is on server 2.

However, I have encounter this problem... when I used PHP mail function to send out emails to Email was not not delivered to on googles' mail servers. However, when I used an pop email on my ISP account, the email successfully reached my google domain email account(s).

My question is this. Did the misdirection came about because frihost's PHP server mistakenly believe that since the domain is pointed to server2 by IP, it assumed responsibility for the MX records as well( MX records on my domain provider is pointed to google). Thus the frihost PHP mail function went and use frihost's assumed MX records and thus failed to delivery the mail to the right account( it went to the catch all account I defined on frihost account instead). Does that mean it is possible for some other senders( non frihost users) to end up with the wrong mail delivery path too? How do I resolve this?

Reason why I want to use google domain mail service instead of frihost is because of the 50GB storage offered by google. I would rather save my frihost storage space for website. Oh by the way, another possible issue I have is that I counted that my folders added up to less than 20MB of disk usage but directadmin report my usage as 25MB plus...

Thank you for your attention.
I use Google Apps for your Domain too and I had a bit of a problem that I believe to be similar:

When I signed up for the Gmail system, I designated my default admin account to be instead of This meant that when I logged in to the webmail system as user, if I sent any emails they were delivered from admin. This did not affect the pop/smtp service though, so emails sent from a mail client were still from

There is something unusual about the admin accounts with Google Apps, so I suggest that you try what I did to solve my problem:

My advice is to create a new admin account called and set it up as the administrator. You can then delete your original account then re-create it as a standard user (non-admin) account. Once you've done that, you can tell Gmail to forward all emails to to

If you delete your original account (, you will need to wait 5 days before it can be re-created. You can set up a mail list to accept emails sent to and deliver them to - this way you will receive your emails but you won't be able to send them from until you re-create the account and have waited the 5 days.
More information is available at this Google help page and this Google help page.

As I said, the problems you're having aren't exactly the same as I had, but I think it could be related to the way Google Apps deals with the admin account - why not give this a try and see if it helps.
if you want to be sure where your PHP point for your domain MX record, run this script




function getmxrrr($hostname, &$mxhosts)
   $mxhosts = array();
   exec('nslookup -type=mx '.$hostname, $result_arr);
   foreach($result_arr as $line)
     if (preg_match("/.*mail exchanger = (.*)/", $line, $matches))
         $mxhosts[] = $matches[1];
   return( count($mxhosts) > 0 );

if (getmxrrr("$YOUR_HOST_HERE", $MXHost))  {
 for ($i=0; $i < count($MXHost); $i++) {
   echo $MXHost[$i];
   echo "<br />";
} else {
 echo "MX record not found for ";
 echo "<br />";

just change to your domain

see if it goes to google or frih.

my domain pointed to google.

you can check here is in server 2
ya, it think if we already set domain here, the DNS server in server 2 will have MX record pointed to server 2 and exim will just deliver it locallly. my php script also fail to deliver mail outside.
Thanks Animal and Badai.

@Animal, nah it is not google. Only email sent from Frihost seem not to be able to reach the google mail.


Ya, the MX records appear to point to google servers but frih mail delivery system still send the mail to its' squirrel mail system instead.
Before the mail is actually sent, try adding this line, changing the IP to the same as your MX record.
ini_set('SMTP', '***.***.***.***');
doesn't work.

and the strange thing is, there is extra line in e-mail body:


mathiaus wrote:
Before the mail is actually sent, try adding this line, changing the IP to the same as your MX record.
ini_set('SMTP', '***.***.***.***');
smtp work in windows only?
badai wrote:
smtp work in windows only?

Embarassed Yeah sorry. I was comparing to issues I had on my local server. Just ignore that suggestion.
this is what i did

apply free subdomain from

set the MX record in

create domain alias in google

now all my php script will send e-mail to user@domain.alias
Related topics
Google Hacked?
Google Registers A Few New Domain Names
Domain Name Issue
When do you estimate the end of M$ products? Ţeklinde 2gb Mail (100 tane)
Blogger on Frihost
E-mails together with your domain name (read more)
Want to show my love for frihost
google maps
Funny domains
Pixlr : an online photo editor
Issue with connecting to the internet
Free Hosting
350 points exchange
Reply to topic    Frihost Forum Index -> Support and Web Hosting -> Web Hosting Support

© 2005-2011 Frihost, forums powered by phpBB.