I'm looking for someone that knows how to setup a basic HTML layout that will use a php file or not in which there will be 10 Questions. The boxes for text will be of enough to put in a few sentences as needed to place answers in and once these answers are all filled in click Submit and it sends the questions along side the results to an email of my choice.
I've set up a few feedback forms from templates I've found online but editing them so far has drove me nuts as the form doesn't seem to be sending. If you know how to do this please PM me...you can just put in temp questions and a temp email I'll edit them later.
I only need a total of 10 Question slots
This is basically going to be used on a site that has full up to date php versions etc etc..so don't worry about that.
Thanks
Here is the code if someone can see what is wrong.
This is the html file named - Tier2Application.html
<tbody><tr> <td valign="top"> <label for="age">What is your age? </label> </td> <td valign="top"> <input type="text" name="age" maxlength="50" size="30"> </td> </tr>
<tr> <td valign="top" "=""> <label for="Time_Zone">What Time Zone/Country do you live in? </label> </td> <td valign="top"> <input type="text" name="Time_Zone" maxlength="50" size="30"> </td> </tr> <tr> <td valign="top"> <label for="Extra_abilities">What other servers do you currently have extra abilities with ie: VIP, Donator, Admin etc etc? </label> </td> <td valign="top"> <textarea type="text" name="Extra_abilities" maxlength="1000" cols="25" rows="6"><textarea> </td>
</tr> <tr> <td valign="top"> <label for="position">Tell us why you think you should hold this position.</label> </td> <td valign="top"> <textarea type="text" name="position" maxlength="1000" cols="30" rows="6"><textarea> </td> </tr> <tr> <td valign="top"> <label for="dedicate">How much time do you dedicate to our Servers in a week?</label> </td> <td valign="top"> <input name="dedicate" maxlength="70" size="30"> </td> <tr> <td valign="top"> <label for="improve">Tell us how you could help us to improve our community and servers.</label> </td> <td valign="top"> <textarea type="text" name="improve" maxlength="1000" cols="30" rows="6"><textarea> </td> </tr> <tr> <td valign="top"> <label for="Opinion">What do you think of the servers at this time?</label> </td> <td valign="top"> <textarea type="text" name="Opinion" maxlength="1000" cols="30" rows="6"><textarea> </td> </tr> <tr> <td valign="top"> <label for="Duration">How long have you been a part of this function?</label> </td> <td valign="top"> <textarea type="text" name="Duration" maxlength="1000" cols="30" rows="6"><textarea> </td> </tr> <tr> <td valign="top"> <label for="Rep_Thread">Do you have a site? If so please provide URL.</label> </td> <td valign="top"> <textarea type="text" name="Rep_Thread" maxlength="1000" cols="30" rows="6"><textarea> </td> </tr> <tr> <td valign="top"> <label for="populate">What suggestions would you give to enhance the servers to help populate them more?</label> </td> <td valign="top"> <textarea type="text" name="populate" maxlength="1000" cols="30" rows="6"><textarea> </td> </tr>
// CHANGE THE TWO LINES BELOW $webmaster_email = "[email protected]";
$email_subject = "Tier2 Application";
function died($error) { // your error code can go here echo "We are very sorry, but there were error(s) found with the form you submitted. "; echo "These errors appear below.
"; echo $error."
"; echo "Please go back and fix these errors.
"; die(); }
// validation expected data exists if(!isset($_POST['age']) || !isset($_POST['Time_Zone']) || !isset($_POST['Extra_abilities']) || !isset($_POST['position']) || !isset($_POST['dedicate']) || !isset($_POST['improve']) || !isset($_POST['Opinion']) || !isset($_POST['Duration']) || !isset($_POST['Rep_Thread']) || !isset($_POST['populate'])) { died('We are sorry, but there appears to be a problem with the form you submitted.'); }
I see it has more memory, more storage, a better CPU, and a stylus, as you said.
Might be a good alternative. I see some refurbished for $150-200.
I'm not scared of refurnbished, as a lot of parts in my house are refurbished/used. All are working atm.
"TeamViewer is the fast, simple and friendly solution for remote access over the Internet"
Regarding the "friendly" description, has is stopped unceremoniusly booting your session after a couple of minutes accusing you of using it in a commercial environment?!
I hate religious supremacist genocidal maniacs. How antisemitic of you to imply that's what all Jews are like. Still no links I see. I guess when you're a zionists, backing your claims with proof doesn't matter. bEliEvE mE oR yOuRe hItLeR.
Question
sava700
I'm looking for someone that knows how to setup a basic HTML layout that will use a php file or not in which there will be 10 Questions. The boxes for text will be of enough to put in a few sentences as needed to place answers in and once these answers are all filled in click Submit and it sends the questions along side the results to an email of my choice.
I've set up a few feedback forms from templates I've found online but editing them so far has drove me nuts as the form doesn't seem to be sending. If you know how to do this please PM me...you can just put in temp questions and a temp email I'll edit them later.
I only need a total of 10 Question slots
This is basically going to be used on a site that has full up to date php versions etc etc..so don't worry about that.
Thanks
Here is the code if someone can see what is wrong.
This is the html file named - Tier2Application.html
here is the php file named html_form_send.php
<?php
if(isset($_POST['email'])) {
// CHANGE THE TWO LINES BELOW
$webmaster_email = "[email protected]";
$email_subject = "Tier2 Application";
function died($error) {
// your error code can go here
echo "We are very sorry, but there were error(s) found with the form you submitted. ";
echo "These errors appear below.
";
echo $error."
";
echo "Please go back and fix these errors.
";
die();
}
// validation expected data exists
if(!isset($_POST['age']) ||
!isset($_POST['Time_Zone']) ||
!isset($_POST['Extra_abilities']) ||
!isset($_POST['position']) ||
!isset($_POST['dedicate']) ||
!isset($_POST['improve']) ||
!isset($_POST['Opinion']) ||
!isset($_POST['Duration']) ||
!isset($_POST['Rep_Thread']) ||
!isset($_POST['populate'])) {
died('We are sorry, but there appears to be a problem with the form you submitted.');
}
$age = $_POST['age']; // required
$Time_Zone = $_POST['Time_Zone']; // required
$Extra_abilities = $_POST['Extra_abilities']; // required
$position = $_POST['position']; // required
$dedicate = $_POST['dedicate']; // required
$improve = $_POST['improve']; // required
$Opinion = $_POST['Opinion']; // required
$Duration = $_POST['Duration']; // required
$Rep_Thread = $_POST['Rep_Thread']; // required
$populate = $_POST['populate']; // required
$error_message = "";
$email_exp = '/^[A-Za-z0-9._%-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}$/';[/size][/font]
[font="Verdana"][size="2"] }
if(strlen($error_message) > 0) {
died($error_message);
}
$email_message = "Form details below.\n\n";
function clean_string($string) {
$bad = array("content-type","bcc:","to:","cc:","href");
return str_replace($bad,"",$string);
}
$email_message .= "First Name: ".clean_string($first_name)."\n";
$email_message .= "Last Name: ".clean_string($Time_Zone)."\n";
$email_message .= "Email: ".clean_string($email_from)."\n";
$email_message .= "position: ".clean_string($position)."\n";
$email_message .= "dedicate: ".clean_string($dedicate)."\n";
$email_message .= "improve: ".clean_string($improve)."\n";
$email_message .= "Opinion: ".clean_string($Opinion)."\n";
$email_message .= "Duration: ".clean_string($Duration)."\n";
$email_message .= "Rep_Thread: ".clean_string($Rep_Thread)."\n";
$email_message .= "populate: ".clean_string($populate)."\n";
// create email headers
$headers = 'From: '.$email_from."\r\n".
'Reply-To: '.$email_from."\r\n" .
'X-Mailer: PHP/' . phpversion();
@mail($email_to, $email_subject, $email_message, $headers);
?>
<!-- place your own success html below -->
Thank you for the application. We will be in touch with you very soon.
<?php
die();
?>
[/CODE]
Be sure to remove this from the code above at the bottom cause for some stupid reason it keeps adding it to the code
/size /font font=verdana size=2 ALL THIS WITHOUT THE BRACKETS...damn stuff!!</textarea></td></tr></tbody></table></form>
Link to comment
https://www.neowin.net/forum/topic/1079759-help-making-a-qa-form/Share on other sites
12 answers to this question
Recommended Posts