Online form
I have taken over a site for a Mortgage Company and his online form doesn't work. It does not send the info to email. Please someone help I am not familiar with the code. Here is the link:
https://www.financingadream.com/purchase_app.htm
Thanks,
Aaron
On the page you posted, this line
HTML Code:
<td> <form action=purchase.php "method=post class="style41" onSubmit="return require('FirstName,Email')" "requiredInputs>
is not properly written. There's a problem with the quotes. It should look like this:
HTML Code:
<td> <form action="purchase.php" method=post class="style41" onSubmit="return require('FirstName,Email')" requiredInputs>
If the problem still persists after that change, you'll need to post the page "purchase.php" to identify the exact problem.
Fixed the "" but the form still did not send the mail. Any other suggestions? I appreciate the help...
Thanks,
Aaron
PHP Page
<?php
include "footer.php";
if(!$_POST) {
?>
<?
}
else {
$to = "akali@financingadream.com";
$subject = "Form Submission Purchase App";
$from = "admin@financingadreamcom";
$message="A Visitor at Financingadream.com has submitted this form.<br><br>
Loan_Program:".$HTTP_POST_VARS["LoanProgram"]"<br>
Loan_Purpose:".$HTTP_POST_VARS["LoanPurpose"]."<br>
Loan_Amount:".$HTTP_POST_VARS["LoanAmount"]."<br>
Property_Value:".$HTTP_POST_VARS["PropertyValue"]."<br>
Time_Frame:".$HTTP_POST_VARS["EstimatedTimeframe"]."<br>
Property_Type:".$HTTP_POST_VARS["PropertyType"]."<br>
Address:".$HTTP_POST_VARS["Address"]."<br>
City:".$HTTP_POST_VARS["City"]."<br>
State:".$HTTP_POST_VARS["State"]."<br>
Zip:".$HTTP_POST_VARS["Zip"]."<br>
First_Name:".$HTTP_POST_VARS["FirstName"]."<br>
Last_Name:".$HTTP_POST_VARS["LastName"]."<br>
SSNa:".$HTTP_POST_VARS["SSNa"]."<br>
SSNb:".$HTTP_POST_VARS["SSNb"]."<br>
SSNc:".$HTTP_POST_VARS["SSNc"]."<br>
Day_Time_Area:".$HTTP_POST_VARS["WorkPhoneArea"]."<br>
Day_Time_Pre:".$HTTP_POST_VARS["WorkPhonePre"]."<br>
Day_Time_Num:".$H TTP_POST_VARS["WorkPhoneNum"]."<br>
Eve_Phone_Area:".$HTTP_POST_VARS["HomePhonea"]."<br>
Eve_Phone_Pre:".$HTTP_POST_VARS["HomePhoneb"]."<br>
Eve_Phone_Num:".$HTTP_POST_VARS["HomePhonec"]."<br>
Email:".$HTTP_POST_VARS["Email"]."<br>
Self_Employed:".$HTTP_POST_VARS["SelfEmployed"]."<br>
Years_Employed:".$HTTP_POST_VARS["YearsEmployed"]."<br>
Annual_Income:".$HTTP_POST_VARS["AnnualIncome"]."<br>
Monthly_Expenses:".$HTTP_POST_VARS["MonthlyExpenses"]."<br>
Credit_History:".$HTTP_POST_VARS["CreditHistory"]."<br>
Comments:".$HTTP_POST_VARS["txtComments"]."<br>
Find_Us:".$HTTP_POST_VARS["lstFindUs"];
$header="Content-type: text/html\nFrom:".$from."\r\n";
mail($to,$subject,$message,$header);
echo "<br><b><br>
</a></b><br><br><br>";
}
?>
Please change all instance of $HTTP_POST_VARS[] to $_POST[], just to be on the safe side.
Also, there was an error on this line:
PHP Code:
Day_Time_Num : ". $H TTP_POST_VARS[" WorkPhoneNum "]." < br >
The space in "H TTP" shouldn't be there...
<?php
include "footer.php";
if(!$_POST) {
?>
<?
}
else {
$to = "akali@financingadream.com";
$subject = "Form Submission Purchase App";
$from = "admin@financingadream.com";
$message="A Visitor at Financingadream.com has submitted this form.<br><br>
Loan_Program:".$_POST["LoanProgram"]."<br>
Loan_Purpose:".$_POST["LoanPurpose"]."<br>
Loan_Amount:".$_POST["LoanAmount"]."<br>
Property_Value:".$_POST["PropertyValue"]."<br>
Time_Frame:".$_POST["EstimatedTimeframe"]."<br>
Property_Type:".$_POST["PropertyType"]."<br>
Address:".$_POST["Address"]."<br>
City:".$_POST["City"]."<br>
State:".$_POST["State"]."<br>
Zip:".$_POST["Zip"]."<br>
First_Name:".$_POST["FirstName"]."<br>
Last_Name:".$_POST["LastName"]."<br>
SSNa:".$_POST["SSNa"]."<br>
SSNb:".$_POST["SSNb"]."<br>
SSNc:".$_POST["SSNc"]."<br>
Day_Time_Area:".$_POST["WorkPhoneArea"]."<br>
Day_Time_Pre:".$_POST["WorkPhonePre"]."<br>
Day_Time_Num:".$_POST["WorkPhoneNum"]."<br>
Eve_Phone_Area:".$_POST["HomePhonea"]."<br>
Eve_Phone_Pre:".$_POST["HomePhoneb"]."<br>
Eve_Phone_Num:".$_POST["HomePhonec"]."<br>
Email:".$_POST["Email"]."<br>
Self_Employed:".$_POST["SelfEmployed"]."<br>
Years_Employed:".$_POST["YearsEmployed"]."<br>
Annual_Income:".$_POST["AnnualIncome"]."<br>
Monthly_Expenses:".$_POST["MonthlyExpenses"]."<br>
Credit_History:".$_POST["CreditHistory"]."<br>
Comments:".$_POST["txtComments"]."<br>
Find_Us:".$_POST["lstFindUs"];
$header="Content-type: text/html\nFrom:".$from."\r\n";
mail($to,$subject,$message,$header);
echo "<br><b><br>
</a></b><br><br><br>";
}
?>
I made the changes still no go.
Try this:
Code:
<?php
include "footer.php";
if($_POST) {
$to = "akali@financingadream.com";
$subject = "Form Submission Purchase App";
$from = "admin@financingadream.com";
$message = "
A Visitor at Financingadream.com has submitted this form.<br>
."<br>Loan_Program: " . $_POST["LoanProgram"]
."<br>Loan_Purpose: " . $_POST["LoanPurpose"]
."<br>Loan_Amount: " . $_POST["LoanAmount"]
."<br>Property_Value: " . $_POST["PropertyValue"]
."<br>Time_Frame: " . $_POST["EstimatedTimeframe"]
."<br>Property_Type: " . $_POST["PropertyType"]
."<br>Address: " . $_POST["Address"]
."<br>City: " . $_POST["City"]
."<br>State: " . $_POST["State"]
."<br>Zip: " . $_POST["Zip"]
."<br>First_Name: " . $_POST["FirstName"]
."<br>Last_Name: " . $_POST["LastName"]
."<br>SSNa: " . $_POST["SSNa"]
."<br>SSNb: " . $_POST["SSNb"]
."<br>SSNc: " . $_POST["SSNc"]
."<br>Day_Time_Area: " . $_POST["WorkPhoneArea"]
."<br>Day_Time_Pre: " . $_POST["WorkPhonePre"]
."<br>Day_Time_Num: " . $_POST["WorkPhoneNum"]
."<br>Eve_Phone_Area: " . $_POST["HomePhonea"]
."<br>Eve_Phone_Pre: " . $_POST["HomePhoneb"]
."<br>Eve_Phone_Num: " . $_POST["HomePhonec"]
."<br>Email: " . $_POST["Email"]
."<br>Self_Employed: " . $_POST["SelfEmployed"]
."<br>Years_Employed: " . $_POST["YearsEmployed"]
."<br>Annual_Income: " . $_POST["AnnualIncome"]
."<br>Monthly_Expenses: ". $_POST["MonthlyExpenses"]
."<br>Credit_History: " . $_POST["CreditHistory"]
."<br>Comments: " . $_POST["txtComments"]
."<br>Find_Us: " . $_POST["lstFindUs"]
;
$header="Content-type: text/html\nFrom: $from\r\n";
mail($to,$subject,$message,$header);
}
?>
It gave me this error
Parse error: syntax error, unexpected '>' in /home/irv1ng/public_html/purchase.php on line 14
Change this:
PHP Code:
$message = "
A Visitor at Financingadream.com has submitted this form.<br>
to:
PHP Code:
$message = "A Visitor at Financingadream.com has submitted this form.<br>"
Thanks I'm going to test it, I will let you know what happens. Again I appreciate your help on this.
Aaron
No errors but still no email. I dont understand?
For now, try changing this:
PHP Code:
mail ( $to , $subject , $message , $header );
to:
PHP Code:
mail ( $to , $subject , $message , $from );
$from would need to have "\r\n" added to it. My omission...
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Bookmarks