www.webdeveloper.com
Page 1 of 2 12 LastLast
Results 1 to 15 of 21

Thread: Online form

  1. #1
    Join Date
    Mar 2006
    Posts
    59

    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

  2. #2
    Join Date
    Dec 2006
    Location
    Escaz˙ (Costa Rica) and Mallorca (Spain)
    Posts
    3,234
    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.

  3. #3
    Join Date
    Mar 2006
    Posts
    59
    Thanks I will try it

  4. #4
    Join Date
    Mar 2006
    Posts
    59
    Fixed the "" but the form still did not send the mail. Any other suggestions? I appreciate the help...

    Thanks,

    Aaron

  5. #5
    Join Date
    Mar 2006
    Posts
    59

    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>";
    }
    ?>

  6. #6
    Join Date
    Dec 2006
    Location
    Escaz˙ (Costa Rica) and Mallorca (Spain)
    Posts
    3,234
    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...

  7. #7
    Join Date
    Mar 2006
    Posts
    59
    <?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.

  8. #8
    Join Date
    Dec 2006
    Location
    Escaz˙ (Costa Rica) and Mallorca (Spain)
    Posts
    3,234
    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);
    }
    ?>

  9. #9
    Join Date
    Mar 2006
    Posts
    59

    It gave me this error

    Parse error: syntax error, unexpected '>' in /home/irv1ng/public_html/purchase.php on line 14

  10. #10
    Join Date
    Dec 2006
    Location
    Escaz˙ (Costa Rica) and Mallorca (Spain)
    Posts
    3,234
    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>" 

  11. #11
    Join Date
    Mar 2006
    Posts
    59
    Thanks I'm going to test it, I will let you know what happens. Again I appreciate your help on this.

    Aaron

  12. #12
    Join Date
    Mar 2006
    Posts
    59
    No errors but still no email. I dont understand?

  13. #13
    Join Date
    Dec 2006
    Location
    Escaz˙ (Costa Rica) and Mallorca (Spain)
    Posts
    3,234
    For now, try changing this:
    PHP Code:
    mail($to,$subject,$message,$header); 
    to:
    PHP Code:
    mail($to,$subject,$message,$from); 

  14. #14
    Join Date
    Mar 2006
    Posts
    59
    still no email

  15. #15
    Join Date
    Dec 2006
    Location
    Escaz˙ (Costa Rica) and Mallorca (Spain)
    Posts
    3,234
    $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
  •  
HTML5 Development Center



Recent Articles