skip to Main Content

Autocomplete from fields above – Jquery

I have this form: <form> <input type="text" class="name" id="name1"> <input type="text" class="name" id="name2"> <input type="text" class="name" id="name3"> ... <input type="text" class="name" id="name100"> <input type="submit" value="Send"> </form> <script> $(document).ready(function() { var items = [ "", ]; $(".name").autocomplete({ source: items }); $('.name').on('keyup',…

VIEW QUESTION

I'm trying to take gender as input in php but I can't validate the input

<label>Gender<span class="note">*</span>:</label> <select name="gender"> <option value="1" selected <?= ($_POST['gender'] == "1")? "selected":"";?>>Select</option> <option value="male" <?= ($_POST['gender'] == "2")? "selected":"";?>>Male</option> <option value="female" <?= ($_POST['gender'] == "3")? "selected":"";?>>Female</option> </select> <?php echo "<p class='note'>".$msg_gender."</p>";?> if (isset($_POST['submit'])) { $gender = $_POST['gender']; if($gender != "2"…

VIEW QUESTION
Back To Top
Search