HTML - Php Feedback Form
Hi all,
I had created a feedback form using the tutorial found he http://www.thesitewizard.com/getting...mweaver6.shtml In that tutorial if the user leaves a required field empty they will be taken to a seperate error page (and a seperate thank you page for when a comment is sent successfully). I'd like to know how to change it so that a small window appears, much like how the following is set up: http://www.easynic.com/feedback.php?interest=true Or alternatively, have a line appear on the page indicating that a mistake has been made (while having the window appear for a successfully sent comment). Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> </head> <? $mailto = 'eoghandevlin@btinternet.com' ; $subject = "EPD Q. S. Solutions Comment" ; $formurl = "http://www.epd-qs-solutions.com/comments.htm" ; $errorurl = "http://www.epd-qs-solutions.com/error.htm" ; $thankyouurl = "http://www.epd-qs-solutions.com/thankyou.htm" ; $uself = 0; $headersep = (!isset( $uself ) || ($uself == 0)) ? "\r\n" : "\n" ; $fname = $_POST['fname'] ; $sname = $_POST['sname'] ; $telephone = $_POST['telephone'] ; $email = $_POST['email'] ; $comments = $_POST['comments'] ; $http_referrer = getenv( "HTTP_REFERER" ); if (!isset($_POST['email'])) { header( "Location: $formurl" ); exit ; } if (empty($fname) || empty($sname) || empty($telephone) || empty($comments)) { header( "Location: $errorurl" ); exit ; } if ( ereg( "[\r\n]", $fname ) || ereg( "[\r\n]", $sname ) || ereg( "[\r\n]", $telephone ) ) { header( "Location: $errorurl" ); exit ; } if (get_magic_quotes_gpc()) { $comments = stripslashes( $comments ); } $messageproper = "This message was sent from:\n" . "$http_referrer\n" . "------------------------------------------------------------\n" . "Name of sender: $fname\n, $sname\n" . "Email of sender: $email\n" . "------------------------- COMMENTS -------------------------\n\n" . $comments . "\n\n------------------------------------------------------------\n" ; mail($mailto, $subject, $messageproper, "From: \"$fname\" \"$sname\" <$email>" . $headersep . "Reply-To: \"$name\" <$email>" . $headersep . "X-Mailer: chfeedback.php 2.07" ); header( "Location: $thankyouurl" ); exit ; ?> <body> </body> </html> Any help is greatly appreciated! Niall Similar Tutorials................................................................................................. Hi Guys, I'm trying to put together a simple feedback form floating on top of my background image. However the form shows up with scroll bars on right side and bottom of the form. I've no idea why. How can I get it to just show up as normal without the scroll option? Thanks guys! HTML Code: <style type="text/css"> #main { width:689px; margin:auto; font-family:verdana,sans-serif; font-size:12px; } #header { height:600px; width:700px; background-image:url(http://i827.photobucket.com/albums/zz193/colinbrady1985/CLUB/ClubApp02. jpg); } #header a { float:left; width:140px; height:115px; text-indent:-9999px; } #header div { float:left; width:360px; height:107px; padding:10px; color:#fff; overflow:auto; } img { display:block; border:0; } form { width:517px; padding-top:10px; margin:0; background-color:#01abe8; } form p { padding:0 5px; font-size:11px; color:#fff; text-align:center; } form div { padding-bottom:10px; } form label { float:left; width:146px; padding-left:5px; color:#fff; } form .required{ font-size: 13px; color:#f00; } form .btn { margin-left:153px; } form .btn1 { margin-left:150px; } </style> <div id="main"> <div id="header"> <a href="">albums</a> <div id="text"><font size="4" face="Arial"> <div> <div style=" top:245px; left:45px;"> <form method="post" action="sendmail.php"> Email: <input name="email" type="text" /><br /> Message:<br /> <textarea name="message" rows="8" cols="20"> </textarea><br /> <input type="submit" /> </form> </div> </div> </div> </div> hi all, Im new on this site.... Im in the process of designing my own site and im finding it difficult to find some code which will allow me to attach a photo to my feedback form and all the data getting sent to my email address, I have completed the whole form and it works fine, i just need some help for attaching a photo option to the form and emailing that to my own email address. Can anyone help please? Thanks is there a script that i can use in my html website to allow a customer to add feedback on my site? Hi there, I have come across a great piece of code work. See the 'Feedback' option at the bottom of this page: http://www.adobe.com/products/ I would so like to incorporate the same on my website. Would greatly appreciate assistance with code. Best, wirefree Hey guys new here so thank you in advance for any help. I am building my first site and I want to have a form on it where users of the page can submit info into a form and then be provided info about that info. For example: How many A's do you want to buy? User inputs a number or selects from a drop down of numbers How many B's do you want to buy? User inputs a number or selects from a drop down of numbers Then I want to the user to see instant feedback on the site that says "Your total is $x.xx" Is this possible? Thanks again I made a directory lister with the following attributes: Images will be displayed as thumbnails Thumbnails are automatically generated Page is automatically updated and redrawn on each access All colors, fonts, and sizes are customizable One index file is required to be placed in each directory It is simply a graphical directory lister - nothing needs to be configured for it to work http://www.phpstory.net/graphics/75 I'm looking for some feedback for improvement and can pretty much make anything happen. It's complete for the most part but I guess first thoughts and suggestions would be helpful in completing the script. I want to make it publicly available at some point and I haven't really gotten enough feedback to call it "finished". It was coded by me 100% - nothing has been borrowed or copied! Thanks!! I have a document I've created in HTML and I'm attempting to be able to have people fill it out and save the results. The document contains radio buttons, check boxes, and text fields that need to be filled out. Now I need a way to have the results saved and sent to me. For some reason I thought if they saved the page after compleating it and e-mailed it to me it would save their results, but it just sends the orriginal page. Any suggestions. script completed, thx Hi all, I have a simple newsletter form, so just the email field and a submit, what I would like to do is to send this data to a larger subscriber form, so one that has name, email (with the data previously entered already added), list to subscribe to etc. Can this be done? Thanks I have a form with a number of elements. One of these elements is: <input type="image" src="https://www.paypal.com/en_US/i/btn/x-click-butcc-subscribe.gif" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!"> Clicking on that element makes the form submit. But if I add a similar element: <input type="image" src="https://www.paypal.com/en_US/i/btn/x-click-butcc-subscribe.gif" border="0" name="submit2" alt="Make payments with PayPal - it's fast, free and secure!"> ...clicking on that also makes the form submit. So was wondering if anyone knew what the rules were for which elements make a form submit? Cheers, James I have a simple signup form on my site that I want to pass the input to the larger signup form. Here is the code for the simple form: <form action="http://bigdogcattle.com/?a=Cattle_Mailing-List_SignUp" method="post" accept-charset="UTF-8"> The larger signup form is located he http://bigdogcattle.com/?a=Cattle_Mailing-List_SignUp I want the email address from the simple form to move to the larger form when the submit button is pressed. Ideas? HTML Code: <form method="post" action="mailto:xxxxxxxx@xx.com "> <table class="text3"> <tr><td valign="top" width="140">Voornaam:</td><td><input name="requiredvoornaam" type="text" id="requiredvoornaam" class="veld" size="30" /></td></tr> <tr><td valign="top" width="140">Achternaam:</td><td><input name="requiredachternaam" type="text" id="requiredachternaam" class="veld" size="30" /></td></tr> <tr><td valign="top">E-mail:</td><td><input name="requiredemail" type="text" id="requiredemail" class="veld" size="30" /></td></tr> <tr><td valign="top">Telefoonnummer:</td><td><input name="requiredtelefoonnummer" type="text" id="requiredtelefoonnummer" class="veld" size="30" /></td></tr> <tr><td valign="top">Adres:</td><td><input name="requiredadres" type="text" id="requiredadres" class="veld" size="30" /></td></tr> <tr><td valign="top">Woonplaats:</td><td><input name="requiredwoonplaats" type="text" id="requiredwoonplaats" class="veld" size="30" /></td></tr> <tr><td valign="top">Aankomstdatum:</td><td><select name="adag" id="adag"> <option value="Dag">Dag</option> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> <option value="7">7</option> <option value="8">8</option> <option value="9">9</option> <option value="10">10</option> <option value="11">11</option> <option value="12">12</option> <option value="13">13</option> <option value="14">14</option> <option value="15">15</option> <option value="16">16</option> <option value="17">17</option> <option value="18">18</option> <option value="19">19</option> <option value="20">20</option> <option value="21">21</option> <option value="22">22</option> <option value="23">23</option> <option value="24">24</option> <option value="25">25</option> <option value="26">26</option> <option value="27">27</option> <option value="28">28</option> <option value="29">29</option> <option value="30">30</option> <option value="31">31</option> </select> <select name="amaand" id="amaand"> <option value="Maand">Maand</option> <option value="Januari">Januari</option> <option value="Februari">Februari</option> <option value="Maart">Maart</option> <option value="April">April</option> <option value="Mei">Mei</option> <option value="Juni">Juni</option> <option value="Juli">Juli</option> <option value="Augustus">Augustus</option> <option value="September">September</option> <option value="Oktober">Oktober</option> <option value="November">November</option> <option value="December">December</option> </select> <select name="ajaar" id="ajaar"> <option value="Jaar">Jaar</option> <option value="2008">2008</option> <option value="2009">2009</option> <option value="2010">2010</option> </select> </td></tr> <tr><td valign="top">Vertrekdatum:</td><td><select name="vdag" id="vdag"> <option value="Dag">Dag</option> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> <option value="7">7</option> <option value="8">8</option> <option value="9">9</option> <option value="10">10</option> <option value="11">11</option> <option value="12">12</option> <option value="13">13</option> <option value="14">14</option> <option value="15">15</option> <option value="16">16</option> <option value="17">17</option> <option value="18">18</option> <option value="19">19</option> <option value="20">20</option> <option value="21">21</option> <option value="22">22</option> <option value="23">23</option> <option value="24">24</option> <option value="25">25</option> <option value="26">26</option> <option value="27">27</option> <option value="28">28</option> <option value="29">29</option> <option value="30">30</option> <option value="31">31</option> </select> <select name="vmaand" id="vmaand"> <option value="Maand">Maand</option> <option value="Januari">Januari</option> <option value="Februari">Februari</option> <option value="Maart">Maart</option> <option value="April">April</option> <option value="Mei">Mei</option> <option value="Juni">Juni</option> <option value="Juli">Juli</option> <option value="Augustus">Augustus</option> <option value="September">September</option> <option value="Oktober">Oktober</option> <option value="November">November</option> <option value="December">December</option> </select> <select name="vjaar" id="vjaar"> <option value="Jaar">Jaar</option> <option value="2008">2008</option> <option value="2009">2009</option> <option value="2010">2010</option> </select> </td></tr> <tr><td valign="top">Welke huisje:</td><td><select name="huisje" id="huisje"> <option value="1">.____Huisje Zomerbries_____.</option> <option value="2">.____Huisje Wervelwind_____.</option> <option value="3">.____Huisje Tornado________.</option> </select> <tr><td valign="top">Aantal personen:</td><td><select name="aantal personen" id="aantal personen"> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> <option value="7">7</option> <option value="8">8</option> </select> <tr><td valign="top">Overige vragen:</td><td><textarea name="bericht" rows="6" cols="23" id="bericht" class="area"></textarea></td></tr> <tr><td valign="top"></td><td><input type="submit" name="sendFormButton" value="Verzenden" id="sendFormButton" /></td> </tr> </table> </form> </td></tr></table> This is what i get once tested... its out of order... Help me plz...... Im not good with those thingz.. So i want to Post and Get in the same form for reasons of keeping the URL looking clean. I need to pass a PHP array through to the next page, and I don't want random gibberish in the URL. So, I can just Post this, but this is for a search page, and it would be nice to Get their search query for the reasons of the advantage of Get over Post, and because it looks better in my opinion. Anyways. The thing I am posting takes no user input, and it is defined in the beginning of the page. The thing I want to Get is user defined in a textbox. So, I need the method of the Form to be Get, but is it possible to also Post something? Thanks, If i wasn't clear i'm sorry and i'll try to explain it better. Hi guy, I tried to do some googling before i come to here. the problem is that i don't know what are the name or keyword for this, therefore i cannot find any relevant result. Let's say, i have many same html with different file name file filled with tables that i dont' want users to open and use it. Can i create another separate forms using html to fill in the blanks on the table cell maybe after i click submit button? Or it's easier to use VB to write a program and do the job? Please help. Hi, I have a tricky problem that you kind people might be able to solve. I want to put one set of forms inside another set of forms without them interfering with each other. At the moment, the form I've created inside the other form is not responding. The code, when simplified, looks something like this: <FORM (1)> <FORM (2)> </FORM> </FORM> Am I trying to do the impossible or is there a way to overcome this problem? Thanks! / Stefan I have created a form with multiple different buttons, the first button is required to open a pop up box to show a list of people who live in a certain postcode. HTML Code: <div id="form"> <form name="f1" method="post"/> <p> ID: <br/> <input name="ID" type="text" value="Leave Blank" /> </p> <p> Name: <br/> <input name="Name" type="text" /> </p> <p> Address: <br/> <input name="Address" type="text" /> </p> <p> Postcode:<br/> <input name="Postcode" type="text" /> <input type='submit' value='Check' onclick="popup('popUpDiv')" /> <p><a href="#" onclick="popup('popUpDiv')">Find Person</a></p> </p> <p> Telephone: <br/> <input name="Telephone" type="text" /> </p> <p> Mobile: <br/> <input name="Mobile" type="text" /> </p> <p> AltTelephone: <br/> <input name="AltTelephone" type="text" /> </p> <p> Email: <br/> <input name="Email" type="text" /> </p> <p> Date: <br/> <input name="Date" type="text" /> </p> <p>Notes: <br/> <input name="Notes" type="text" /> </p> <p> CompanyNotes: <br/> <input name="CompanyNotes" type="text" /> </p> <p> Payment: <br/> <input name="Payment" type="text" value="Leave Blank for 0" /> </p> <p> <input type="submit" Value='Book' onclick="f1.action='insert.php'; return true " /> <!--<div id="wheel"><a href="instructorSearch.php"onClick="return popup(this, 'notes')"><img id="mainLogo" src="im/wheel.png" alt="Driving School Logo" /></a></div> !--> </p> <p><input type="submit" Value='Enquire' onclick="f1.action='insertEnquire.php'; return true " /> </form> The first button on the code works but the pop up only displays for a split second, the hyperlink underneath the button opens the pop up for good but cannot get the variable from the form.... I need help with a form. I am creating a form to send an email, and I need one of the input values to be changed to the contents of a table cell that is somewhere else in the body of the document. That table cell has dynamic content in it so it's not as simple as just doing this: Value="div contents here". I'm sure there is a way to do it, I'm just not sure what that way is. I'm more than willing to use a div instead of a table cell if that helps any. Hello all: Now I am very new to to html and recently tired to create a website. I was cruising along when I got stumped. I have tried to do this on my own without having to post for help without any luck. I have been trying since last week. You all probably think the form in html is so very newbie and im sure your right lol. But I just can't seem to get this form to work right. I want the information submitted in the form to go directly to my email if possible. I would also like to validate and require the user to enter Name, Email and Phone beofre they are able to "submit". Any help would be GREATLY appretiated. Thank you for reading my post. Attached is the html file that I am working with. I am working in Dreamweaver 8. Thanks in advance. Mellisa |