ayomitundea Posted August 22, 2009 Share Posted August 22, 2009 I generate my feedback scripts using Php Form Wizard which i recently purchased. I have however ran into a fix with a form i need to use an auto responder with that will not only send html email but will also attach a logo to send with the mail The generated code for the feedback and auto response is as follows <?php // Receiving variables @$pfw_ip= $_SERVER['REMOTE_ADDR']; @$VTIGROUP = addslashes($_POST['VTI-GROUP']); @$T1 = addslashes($_POST['T1']); @$T2 = addslashes($_POST['T2']); @$T3 = addslashes($_POST['T3']); @$T4 = addslashes($_POST['T4']); @$T5 = addslashes($_POST['T5']); @$T6 = addslashes($_POST['T6']); @$T7 = addslashes($_POST['T7']); @$T8 = addslashes($_POST['T8']); @$T9 = addslashes($_POST['T9']); @$T10 = addslashes($_POST['T10']); @$D1 = addslashes($_POST['D1']); @$T11 = addslashes($_POST['T11']); @$T12 = addslashes($_POST['T12']); @$S1 = addslashes($_POST['S1']); // Validation if (! ereg('[A-Za-z0-9_-]+\@[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+', $T7)) { header("Location: error.html"); exit; } //Sending Email to form owner $pfw_header = "From: $T7\n" . "Reply-To: $T7\n"; $pfw_subject = "Feedback Form from IGODYE's website"; $pfw_email_to = "infoseptemberatts@yahoo.com"; $pfw_message = "Visitor's IP: $pfw_ip\n" . "VTIGROUP: $VTIGROUP\n" . "T1: $T1\n" . "T2: $T2\n" . "T3: $T3\n" . "T4: $T4\n" . "T5: $T5\n" . "T6: $T6\n" . "T7: $T7\n" . "T8: $T8\n" . "T9: $T9\n" . "T10: $T10\n" . "D1: $D1\n" . "T11: $T11\n" . "T12: $T12\n" . "S1: $S1\n"; @mail($pfw_email_to, $pfw_subject ,$pfw_message ,$pfw_header ) ; //Sending auto respond Email to visitor $pfw_header = "From: info@\n" . "Reply-To: info@\n"; $pfw_subject = " Your Booking Request has been Recieved"; $pfw_email_to = "$T7"; $pfw_message = "Dear $T1,\n" . "We have recieved your request for the booking of $D1. A Customer care representative will be looking into your request and will be getting across to you shortly with further information/instructions.\n" . "Thank you for using US.\n" . "HAI"; @mail($pfw_email_to, $pfw_subject ,$pfw_message ,$pfw_header ) ; header("Location: thankyou.html"); ?> Help will be appreciated please... Thank you Quote Link to comment https://forums.phpfreaks.com/topic/171440-php-mail-function-to-send-html-mail-and-attachments/ Share on other sites More sharing options...
MadTechie Posted August 22, 2009 Share Posted August 22, 2009 Your not sending a HTML or attaching the file.. maybe try http://sourceforge.net/projects/phpmailer/ instead Quote Link to comment https://forums.phpfreaks.com/topic/171440-php-mail-function-to-send-html-mail-and-attachments/#findComment-904116 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.