Jump to content

Mailer Code not emailing all information?


jessicakane

Recommended Posts

Hello there all PHP gods, I am in need of help. I'm muddled around quite awhile, broke down and deciding to ask.

 

I finally figured out how to create a custom php mailer script, however, the fields from the form of which the user is entering info is not emailing....just blank?....can anyone help me super please :(.... The name and email all is not entering into the email..hmm?

 

Thank you so much in advance....

 

Jessica

 

************************** CODE ****************

 

<?php

 

$to = "[email protected]"; //change this to your email address

$from = "[email protected]"; /* change this to the email address you want to "send" from */

 

//assign the variables

$subject = $_POST['Purchase Order Submission2'];

$redirect = $_POST['http://www.bullseye-electric.com/thankyou.htm'];

$Business = $_POST['Business'];

$name = $_POST['name'];

$Phone = $_POST['Phone'];

$Email = $_POST['Email'];

$Address1 = $_POST['Address1'];

$Address2 = $_POST['Address2'];

$City = $_POST['City'];

$State = $_POST['State'];

$Zip = $_POST['Zip'];

$LicenseNo = $_POST['LicenseNo'];

$LicenseState = $_POST['licenseState'];

$Comments = $_POST['Comments'];

 

 

 

$msg = <<<HERE

Business Name: $Business

Contact Name: $name

Phone Number: $Phone

Email: $Email

Address: $Address1

$Address2

$city, $state  $zip

License Number: $LicenseNo

State: $LicenseState

 

Comments: $comments

HERE;

 

mail($to, 'New Account Setup Request <'.$subject.'>', $msg, 'From: Bullseye-Electric.com <'.$from.'>');

 

header('Location: http://www.bullseye-electric.com/thankyou.htm'.$redirect);

?>

Link to comment
https://forums.phpfreaks.com/topic/80746-mailer-code-not-emailing-all-information/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.