Jump to content

auto email after form submit errors.


waterwn1097

Recommended Posts

alright so another post- might be a dumb issue on my part. 

I want this email to be sent to my customer when the form is submitted.

<?php include_once("scripts/connect.php");
$message = '';
if(isset($_POST['Submit'])) {

    $id = $_POST['id'];
    $contractlink = $_POST['contractlink'];
    $foliolink = $_POST['foliolink'];
    $status = $_POST['status'];
    $quote = $_POST['quote'];
    $deposit = $_POST['deposit'];
    $vaddress = $_POST['vaddress'];
    $vcity = $_POST['vcity'];
    $vstate = $_POST['vstate'];
    
    $sql = mysql_query("UPDATE clients SET contractlink='$contractlink', foliolink='$foliolink', status='$status', quote='$quote', deposit='$deposit', vaddress='$vaddress',
     vcity='$vcity', vstate='$vstate' WHERE id='$id'"); 
    $message = "The Customers Information has been updated.";
	$lastname = $row['lastName'];


    
$autoreply = "Hi $firstname,
We have uploaded your quote for your event!

Log in back into your account and view our quote offers. If you would like to hire us based on this quote please respond to this email and view the paperwork on your account page.
Thanks! 

Wesley


$replyemail = "From: [email protected]";


mail ("$email", "Alpha Dog Entertainment Quote Now Loaded", $autoreply, $replyemail);
}
?>

however the email is not sending. Please help!!

Link to comment
https://forums.phpfreaks.com/topic/285188-auto-email-after-form-submit-errors/
Share on other sites

alright so another post- might be a dumb issue on my part. 

I want this email to be sent to my customer when the form is submitted.

<?php include_once("scripts/connect.php");
$message = '';
if(isset($_POST['Submit'])) {

    $id = $_POST['id'];
    $contractlink = $_POST['contractlink'];
    $foliolink = $_POST['foliolink'];
    $status = $_POST['status'];
    $quote = $_POST['quote'];
    $deposit = $_POST['deposit'];
    $vaddress = $_POST['vaddress'];
    $vcity = $_POST['vcity'];
    $vstate = $_POST['vstate'];
    
    $sql = mysql_query("UPDATE clients SET contractlink='$contractlink', foliolink='$foliolink', status='$status', quote='$quote', deposit='$deposit', vaddress='$vaddress',
     vcity='$vcity', vstate='$vstate' WHERE id='$id'"); 
    $message = "The Customers Information has been updated.";
	$lastname = $row['lastName'];


    
$autoreply = "Hi $firstname,
We have uploaded your quote for your event!

Log in back into your account and view our quote offers. If you would like to hire us based on this quote please respond to this email and view the paperwork on your account page.
Thanks! 

Wesley


$replyemail = "From: [email protected]";


mail ("$email", "Alpha Dog Entertainment Quote Now Loaded", $autoreply, $replyemail);
}
?>

however the email is not sending. Please help!!

 

Your missing a double quote I believe at the end of your $autoreply string.

thanks for the reply I placed the double quote after the email ending and still no result

thanks

 

Where is your $email variable?

also where have you declared your $row variable?

 

It seems to me that you are editing code that isn't written by you? If so, do you understand how to fetch the result from a mysql query? Your terminates prior to sending the email

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.