Search the Community
Showing results for tags 'contact form mandatory'.
-
Hi All, Please excuse the newbie question but I am struggling with this one. I'm just after some advice on what code to put in and where to make these eight fields mandatory to fill out in the contact page of our site. I've found a lot of sites with code to put in but none seem to work. Apologies for the basic question and appreciate any help given! Here is the current form... (Please ignore the promo and Toybox area as this was used for our sister company in the states) <form method="post" action="db_send-contact-form.php"> <p class="style17">Your Name: <br /> <textarea name="name" rows="1" cols="40" id="name"></textarea> </p> <p class="style22">Company: <br /> <textarea name="company" rows="1" cols="40" id="company"></textarea> </p> <p class="style22">Email:<br /> <textarea name="email" rows="1" cols="40" id="email"></textarea> </p> <p class="style22">When are you looking at having this installed?<br /> <textarea name="when" rows="1" cols="40" id="when"></textarea> </p> <p class="style22">Do you have a Product Code in mind?<br /> <input type='text' name="code" style='width: 300px' id="code" value="<?PHP if(isset($_REQUEST['code'])) { echo $_REQUEST['code']; } if(isset($_REQUEST['toybox'])) { if($_REQUEST['toybox'] == 1) { echo "ToyBox: ". $_COOKIE['ToyBox']; } else { $uID = ''; if(isset($_SESSION['uID'])) { $uID = $_SESSION['uID']; } echo "ToyBox: ". db_getToybox($_REQUEST['toybox'], $uID); } } if($_SESSION['Promotion'] == "PROMO2012APR") { echo " | MUST INCLUDE SALE PRICE"; } ?>" /> </p> <p class="style22">Phone:<br /> <textarea name="phone" rows="1" cols="40" id="phone"></textarea> </p> <p class="style22">City & State:<br /> <textarea name="state" rows="1" cols="40" id="state"></textarea> </p> <p class="style22">Any other info?<br /> <textarea name="message" rows="15" cols="40" id="message"></textarea> </p> <p><br> <input type="submit"> </p> </form>