Guest User

Untitled

a guest
Jul 16th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. <select id="jornada" class="form-control" name="jornada" required>
  2. <option value="">-- SELECCIONE --</option>
  3. <?php
  4. while ($row=mysqli_fetch_array($jornada)) {
  5. echo '<option value='.$row["id"].'>'.$row["jornada"].'</option>';
  6. }
  7. mysqli_free_result($jornada)
  8. ?>
  9. </select>
  10.  
  11. <select id="r_ruta" class="chosen-select" name="r_ruta" required>
  12. <option value="">-- SELECCIONE --</option>
  13. </select>
  14.  
  15. $(document).ready(function(){
  16. $("#jornada").change(function(){
  17. $.get("get_colegios.php","jornada_id="+$("#jornada").val(), function(data){
  18. $("#r_ruta").html(data);
  19. console.log(data);
  20. });
  21. });
  22. });
Add Comment
Please, Sign In to add comment