• Resolved oliwee

    (@oliwee)


    Like other users, I have the problem that since a few weeks no mails will be sent from the plugin. Before that, the mails are sent perfectly, without changes on the server configuration.
    I figured out, that the DNS check fails (class-s2-core.php, line 1029).
    This is a intranet site of my company. The domain is valid, I don’t know why this test will fail. When I skip the test, the mails are sent.

    • This topic was modified 6 years, 12 months ago by oliwee.
    • This topic was modified 6 years, 12 months ago by oliwee.
Viewing 7 replies - 1 through 7 (of 7 total)
  • @oliwee

    If this is an intranet and not public accessible it may not have DNS records to check.

    The other possibility is non-ASCII characters in the domain name.

    Do either of those sound possible?

    Thread Starter oliwee

    (@oliwee)

    Hi,

    the domain name is br-automation.com, and this is an official accessable domain, so there should be DNS records.
    How does the function checkdnsrr() work? Does it try to request the DNS record from a special server, so that our companie’s firewall could block this request?

    Whould it be possible that you implement an option for disable the domain validation for such a case?

    Thanks
    Oli

    @oliwee

    checkdnsrr() works will look up the domain on a Domain Name Server and fail if it finds no entry – checking the domain works for me but the firewall or a poorly configure DNS entry locally may block the check.

    I’ll try to get a filter to bypass this check in the next version.

    @oliwee

    Try the patched and updated code here and see if that fixes your issue:

    https://github.com/mattyrob/subscribe2

    Thread Starter oliwee

    (@oliwee)

    @mattyrob
    Wow, that was fast!
    It works, when I set “s2_validate_email_with_dns” to “false”.

    Is there any way to set that option on the dashboard?

    Thanks for your fast response!

    @oliwee

    I tend to use filters for this type of setting – it’s something that would be set once and should not be touched again so using filter code it better than an dashboard setting that can easily and mistakenly be changed back and break things.

    Adding this to a custom plugin or even functions.php in a theme will work:

    add_filter( 's2_validate_email_with_dns', '__return_false' );

    Thread Starter oliwee

    (@oliwee)

    Thank you for the explanation. I made a child theme and added it to the functions.php.
    Works perfectly!

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘No mails will be sent – DNS validation fails’ is closed to new replies.