PHP Contact Form to Mail not working -


good day everyone, first time post here pls bear me. need guys, i'm artist knows basic html5/css that's why i'm not in php.

anyway have project has contact form, realized yahoo mail not working when fill form online, gmail's good. below php code. i've been following php mail() contact-us form works fine if entering gmail sending address, not yahoo can't on own! brother needs help. thank you.

<?php $field_name = $_post['cf_name']; $field_brand = $_post['cf_brand']; $field_category = $_post['cf_category']; $field_email = $_post['cf_email']; $field_facebook = $_post['cf_facebook']; $field_instagram = $_post['cf_instagram']; $field_number = $_post['cf_number']; $field_message = $_post['cf_message'];  $mail_to = 'dulcetlifestylehub@gmail.com'; $subject = 'dulcet lifestyle - become family: '.$field_name;  $body_message = 'from owner: '.$field_name."\n"; $body_message .= 'brand name: '.$field_brand."\n"; $body_message .= 'brand category: '.$field_category."\n"; $body_message .= 'email: '.$field_email."\n"; $body_message .= 'facebook: '.$field_facebook."\n"; $body_message .= 'instagram: '.$field_instagram."\n"; $body_message .= 'number: '.$field_number."\n"; $body_message .= 'message: '.$field_message;  $headers = 'from: '.$field_email."\r\n"; $headers .= 'reply-to: '.$field_email."\r\n";  $mail_status = mail($mail_to, $subject, $body_message, $headers);  if ($mail_status) { ?>     <script language="javascript" type="text/javascript">         alert('thank message. contact shortly.');         window.location = 'becomefamily.htm';     </script> <?php } else { ?>     <script language="javascript" type="text/javascript">         alert('message failed. please, send email dulcetlifestylehub@gmail.com');         window.location = 'becomefamily.htm';     </script> <?php } ?> 


Comments

Popular posts from this blog

Spring Boot + JPA + Hibernate: Unable to locate persister -

go - Golang: panic: runtime error: invalid memory address or nil pointer dereference using bufio.Scanner -

c - double free or corruption (fasttop) -