Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #278852

    How can I fix the contact form so that e-mails from folks with a yahoo.com address (or any other provider that uses DMARC) get sent out correctly?

    Right now I’m not getting e-mails user’s submit thru the contact form and when checking my error log, this is what I see:

    2014-06-14 00:35:30 1WviUr-0005BP-U8 ** (Email address hidden if logged out) R=dnslookup T=remote_smtp: SMTP error from remote mail server after end of data: host ASPMX.L.GOOGLE.com [2607:f8b0:400e:c01::1b]: 550-5.7.1 Unauthenticated email from yahoo.com is not accepted due to domain’s\n550-5.7.1 DMARC policy. Please contact administrator of yahoo.com domain if\n550-5.7.1 this was a legitimate mail. Please visit\n550-5.7.1 http://support.google.com/mail/answer/2451690 to learn about DMARC\n550 5.7.1 initiative. hr5si7176451pad.89 – gsmtp

    #278870

    Hi wgpubs!

    Yes, a user reported his host doesn’t allow to send emails from a different tld in the past and the only possible fix is to change the sender email. You can use this code to change the sender address – insert it at the bottom of child theme functions.php or enfold/functions.php and replace (Email address hidden if logged out) with your yahoo email address.

    
    add_filter('avf_form_from', 'avia_change_from', 10, 3);
    function avia_change_from($from,$new_post,$params){
    $from = ' (Email address hidden if logged out) ';
    return $from;
    }
    

    Best regards,
    Peter

    #278963

    Thanks reply Dude … I think we are close but not quite there.

    I have my contact form configured to send e-mails to a gmail address (not the same as the domain) and it is also configured to send an automated reply to the user that the form was submitted. Given the solution above, it sends both the e-mail and confirmation e-mail to the address above.

    It seems I need to be able to set the “from” on the confirmation e-mail to the address the user includes in the form as well.

    Thanks – wg

    #279667

    PROBLEM: changing the $from appears to affect the automated reply feature in the theme, so that regardless of what the user specifies as their “from” e-mail in the form, the automated reply is sent to the $from value above.

    Make sense?

    Thanks -wg

    #279930

    Hi!

    Try to use this code instead:

    
    add_filter('avf_form_from', 'avia_change_from', 10, 3);
    function avia_change_from($from,$new_post,$params){
    global $avia_config;
    $avia_config['from_email_address'] = $from;
    $from = ' (Email address hidden if logged out) ';
    return $from;
    }
    
    add_filter('avf_form_autoresponder_from', 'avia_change_autoresponder_from', 10, 3);
    function avia_change_autoresponder_from($from, $new_post, $form_params){
    global $avia_config;
    if(isset($avia_config['from_email_address'])) $from = $avia_config['from_email_address'];
    return $from;
    }
    

    and replace (Email address hidden if logged out) with your yahoo email.

    Cheers!
    Peter

    #280130

    Thanks Peter. That works!

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Contact Form E-mails Not Being Sent because of Yahoo's new DMARC policy’ is closed to new replies.