What's Wrong With This Php Form Code Sef? - Webmasters - Nairaland
Nairaland Forum › Science/Technology › Webmasters › What's Wrong With This Php Form Code Sef? (947 Views)
1 Reply
| What's Wrong With This Php Form Code Sef? by feelme3(op): 12:05am On Aug 19, 2011 |
My people, I greet una. Please, am trying out for the first time to process a Form with php. Somhow, the Form seems to work and even show me the 'thankyou.html' page after I submit but I've been waiting for the form contents (slept and woke up) and it has refused to come reach the email address I directed it to. I've change the email and tried and its still hanging out there in space. So please can somebody graciously take a look at my codes and show me my short-sightedness. Here's the HTML for the form. <script src="js/functions.js"></script> <form method="post" action="sendmail.php" onSubmit="return validateForm(Array('FirstName', 'LastName', 'Email', 'WorkPhone'), this);" name="contact" id="contact"> <input type="hidden" name="Source" value="9" /> <div class="set" id="req-fields"> <h3>Required Info</h3> <label for="FirstName" class="required">First name</label> <input type="text" name="FirstName" class="text" /><br class="clear" /> <label for="LastName" class="required">Last name</label> <input type="text" name="LastName" class="text" /><br class="clear" /> <label for="Email" class="required">Email</label> <input type="text" name="Email" class="text" /><br class="clear" /> <label for="WorkPhone" class="required">Daytime phone</label> <input type="text" name="WorkPhone" class="text" /><br class="clear" /> <div class="field-note">(to discuss your needs and make specific recommendations)</div> <div class="clear"></div> <div class="continue-arrow"></div> </div> <div class="set" id="opt-fields"> <h3>Helpful Info <span class="note">(optional)</span></h3> <label for="BestTimeToContact">Best time to reach you</label> <input type="text" name="BestTimeToContact" class="text" /><br class="clear" /> <label for="DepartureCity">Departure city</label> <input type="text" name="DepartureCity" class="text" /><br class="clear" /> <label for="Destination">Destination</label> <input type="text" name="Destination" class="text" /><br class="clear" /> <label for="TravelDates">When will you travel?</label> <input type="text" name="TravelDates" class="text" /><br class="clear" /> <label for="NumberOfNights">How many nights?</label> <select name="NumberOfNights"> <option>Please select</option> <option value="1-2 Nights">1-2 Nights</option> <option value="3-6 Nights">3-6 Nights</option> <option value="7-9 Nights">7-9 Nights</option> <option value="10-14 Nights">10-14 Nights</option> <option value="Over 14 Nights">Over 14 Nights</option> </select><br class="clear" /> <label for="PerPersonBudget">Your per-person budget</label> <select name="PerPersonBudget"> <option>Please select</option> <option value="under $1000">under $1000</option> <option value="$1001 - $1500">$1001 - $1500</option> <option value="$1500 - 2500">$1500 - 2500</option> <option value="$2501 - $5000">$2501 - $5000</option> <option value="$5000+">$5000+</option> </select><br class="clear" /> <!-- <label for="TravelStyle">Your travel style</label> <select name="TravelStyle"> <option>Please select</option> <option value="Deluxe/luxury">Deluxe/luxury</option> <option value="Good Quality/moderate">Good Quality/moderate</option> <option value="Budget/basic">Budget/basic</option> </select><br class="clear" />--> <label for="HowHeardAbout">How did you hear about us?</label> <select name="HowHeardAbout" class="wide"> <option>Please select</option> <option value="Amtrak.com">Amtrak.com</option> <option value="AOL">AOL</option> <option value="CNBC">CNBC</option> <option value="CruiseCritic">CruiseCritic</option> <option value="Cruiseline referral">Cruiseline referral</option> <option value="Email Specials">Email Specials</option> <option value="Friend/Customer referral">Friend/Customer referral</option> <option value="Google">Google</option> <option value="Google Ad Words">Google Ad Words</option> <option value="Magazine">Magazine</option> <option value="Mailer">Mailer</option> <option value="MSN">MSN </option> <option value="Newspaper">Newspaper</option> <option value="NorthWest Airlines">Northwest Airlines</option> <option value="NWA.com">NWA.com</option> <option value="NWA Worldsperks Visa">NWA Worldsperks Visa</option> <option value="Radio/TV">Radio/TV</option> <option value="TravelZoo">TravelZoo</option> <option value="US Bank">US Bank</option> <option value="Yahoo">Yahoo</option> <option value="Other Search Engine">Other Search Engine</option> <option value="Other">Other</option> </select><br class="clear" /> <label for="Comments" class="comments">Anything else you'd like us to know about this trip so we can best meet your needs</label> <textarea name="Comments"></textarea><br class="clear" /> <div class="clear"></div> <div class="continue-arrow"></div> </div> <div id="submit-box"> <div id="captcha"> <img src="form/captcha.php" alt="" /><br/> Please enter the code shown above: <input MAXLENGTH="8" SIZE="8" name="userstring" type="text" value=""/> </div> <button type="submit">Contact Us!</button> </div> </form> The [b]'sendmail.php' [/b]code: <?php $FirstName = $_REQUEST['FirstName'] ; $LastName = $_REQUEST['LastName'] ; $Email = $_REQUEST['Email'] ; $WorkPhone = $_REQUEST['WorkPhone'] ; mail( "inifriendslink@yahoo.com", "Feedback Form Results", $FirstName, $WorkPhone, $Email ); header( "Location: http://www.multiterrain.com/thankyou.html" ); ?> Abeg, make somebody help me, abeg. ![]() |
Can You Solve This PHP Problem?? • Help To Correct This Php Mailer Code • @Yawa-ti-de:Please Help Me Check This PHP Mailer To See If The Script Is Correct • 2 • 3 • 4
Who Help Me 2 Open A Site Like 2go • Pls Help! • 5 Tips To Increase Your Blog Traffic...
