We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29387
    • 40 Posts
    I’m trying to use eForm 1.4.4 on a ModX 0.9.6.1p2 test site. This runs on a server with Linux - Apache 2.2.8 - MySQL 5.0.45 - PHP 5.2.5 installed.

    Snippet call works perfectly with the following code:
    [!eForm? &formid=`ContactForm` &subject=`[+subject+]` &to=`[email protected]` &ccsender=`1` &tpl=`ContactForm` &report=`ContactFormReport` &gotoid=`46` !]

    This also works fine if I change the "&to=" entry to `[email protected]` (hosted at aplus.net).

    However, when I try to change the "&to=" entry to either `[email protected]` (hosted at ait.com) or `[email protected]` (hosted at a2hosting.com), then no email is sent -- no error message is generated, but no mail goes, either.

    What would cause eForm to only send mail to certain servers? If it works for one, why not for all?
      • 4310
      • 2,310 Posts
      Do the other servers have the PHP mail() function enabled.
      Look in the Manager at Tools => Reports => System Info => php info() => View
        • 29387
        • 40 Posts
        Yes, mail() works fine on both serverA and serverB. I used the following test script to send messages to all of the possible addresses mentioned in my first post:

        <?php
        $to = "[email protected]";
        $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>");
        }
        ?>
          • 4310
          • 2,310 Posts
          I’ve had some email addresses fail due to the host server filtering out certain types of email.
          I knew this was the case because I sent a CC to an address that always received them, which proved they were being sent okay.
            • 29387
            • 40 Posts
            Hmmmmm, truly weird!

            Oh well, at least the ModX snippet seems to be working just fine!

            Thanks for taking a look at this.
              • 29387
              • 40 Posts
              As it turns out, this was an issue involving test site vs. production site. I was porting an old PostNuke site to a new ModX one on a new server -- files were setup on new server but domain name transfer had not been completed yet.

              New ISP saw folder for [not yet transferred] site and added it to their "localdomains" file -- thus any email sent from a form on my test site to an address for that domain was directed to the new server -- and died there, of course, since the mail account was not active there yet.

              If this ever happens to a test site you’re running, you can either (a) ignore it, until the domain name transfer occurs or (b) ask your new ISP to temporarily move that domain to its "remotedomains" file.