Click here to Skip to main content
15,887,027 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
This is the HTML Page that i have.....


XML
<html>
<head>
<title>Application for KKLS</title>
<style type="text/css">
.form{
    position: fixed;
    top: 90px;
    left: 90px;
}
body{
    background-color: #000000;
    color: #ffffff !important;
}
</style>
</head>
<body>

<div class="form">
<form name="Application" method="post" action="Application_send.php">
<table width="450px">
</tr>
<tr>
 <td valign="top">
  <label for="name">First Name *</label>
 </td>
 <td valign="top">
  <input  type="text" name="name" maxlength="50" size="30">
 </td>
</tr>

<tr>
 <td valign="top"">
  <label for="psn">PSN *</label>
 </td>
 <td valign="top">
  <input  type="text" name="PSN" maxlength="50" size="30">
 </td>
</tr>
<tr>
 <td valign="top">
  <label for="residence">were do you live *</label>
 </td>
 <td valign="top">
  <input  type="text" name="residence" maxlength="80" size="30">
 </td>

</tr>
<tr>
 <td valign="top">
  <label for="DOB">Date Of Birth *</label>
 </td>
 <td valign="top">
  <input  type="text" name="DOB" maxlength="30" size="30">
 </td>
</tr>
<tr>
 <td valign="top">
  <label for="strengths">Brief desciption of strengths and weaknesses on COD? *</label>
 </td>
 <td valign="top">
  <textarea  name="strengths" maxlength="1500" cols="25" rows="8"></textarea>
 </td>
 <tr>
 <td valign="top">
  <label for="active">How actively are you on COD? *</label>
 </td>
 <td valign="top">
  <textarea  name="active" maxlength="100" cols="25" rows="3"></textarea>
 </td>
</tr>
<tr>
 <td valign="top">
  <label for="role">If you were put on a team what would you want your role to be? *</label>
 </td>
 <td valign="top">
  <textarea  name="role" maxlength="100" cols="25" rows="3"></textarea>
 </td>
</tr>
<tr>
 <td valign="top">
  <label for="KKLS">What makes you right for KKLS? *</label>
 </td>
 <td valign="top">
  <textarea  name="KKLS" maxlength="1500" cols="25" rows="8"></textarea>
 </td>

</tr>

</tr>
<tr>
 <td colspan="2" style="text-align:center">
  <input type="submit" value="Submit">
 </td>
</tr>
</table>
</form>
</div>



</body>
</html>



This is the php page i have to follow the instructions on the HTML page.....



XML
<?php
$field_name = $_POST['name'];
$field_PSN = $_POST['PSN'];
$field_residence = $_POST['residence'];
$field_DOB = $_POST['DOB'];
$field_strengths = $_POST['strengths'];
$field_active = $_POST['active'];
$field_role = $_POST['role'];
$field_KKLS = $_POST['KKLS'];

$mail_to = 'kkls@klutchkillas.com';
$subject = 'KKLS application '.$field_name;

$body_message = 'Applicant: '.$field_name."\n";
$body_message .= 'PSN: '.$field_PSN."\n";
$body_message .= 'Residence: '.$field_residence."\n";
$body_message .= 'DOB: '.$field_DOB."\n";
$body_message .= 'strengths: '.$field_strengths."\n";
$body_messege .= 'active: '.$field_active."\n";
$body_messege .= 'role: '.$field_role."\n";
$body_messege .= 'KKLS: '.$field_KKLS."\n";

$headers = 'From: '.$field_psn."\r\n";
$headers .= 'Reply-To: '.$field_psn."\r\n";

$mail_status = mail($mail_to, $subject, $body_message, $headers);

if ($mail_status) { ?>
    <script language="javascript" type="text/javascript">
        alert('Thank you for your interest in Klutch Killas. for the next step in the aplication prosseces go <a href=klutchkillas.com>here</a>');
        window.location = 'formz';
    </script>
<?php
}
else { ?>
    <script language="javascript" type="text/javascript">
        alert('Message failed. Please, send an email to kkls@klutchkillas.com');
        window.location = 'klutchkillas.com';
    </script>
<?php
}
?>



I do realize that the code for the popup is broken i will figure that out when i get there for now i need the form to email ALL of the fields to the specified email as of right now its only emailing half the fields. For the life of me i cant figure this out can any one help?
Posted
Updated 24-Oct-13 3:30am
v2

1 solution

Check the accepted answer of this question.!!
How to create a registration form using HTML and style sheets[^]
and to know in detail you can visit This[^], This[^], This for specially PHP[^], In PHP 2[^] and this[^] links. You could resolve your problem.
 
Share this answer
 
Comments
ChazorTheTormented 24-Oct-13 9:28am    
Most of the links you posted are not explaining the mail to php script im trying to figure out why only five fields are being emailed when there are 8 in my form :) thank you for your time.
as i said the email that is recived ends up not having the active,role or KKLS fields just the first fivi have the html form basicaly written but the ones you posted really wont work in my application of the form
i am also not trying to create a user base in sql on this site
im truely not trying to sound ungreatfull for the help i have been trying to figure out why this isnt working for about a week now with no luck

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900