Well, I have a bootstrap Dropbox on this page and depending on the value selected I need to fire the SQL Query and only list down students of that particular batch.
//THE DROPBOX CODE
<tr>
<td>
<h5>'.$subject_name[$i].'</h5>
</td>
<td>0</td>
<td>
<div class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown">
<span id="'.$j.'" class="abc">Theory</span>
<span class="caret"></span></a>
<ul class="dropdown-menu '.$j.'"" onclick="drop(event);">
<li select value="theory"><a href="#">Theory</a></li>
<li class="divider"></li>
<li value="Practical A"><a href="#">Practical - A</a></li>
<li value="Practical B"><a href="#">Practical - B</a></li>
<li value="Practical C"><a href="#">Practical - C</a></li>
<li class="divider"></li>
<li value="Elective PCD"><a href="#">Electives - PCD</a></li>
<li value="Elective OR"><a href="#">Electives - OR</a></li>
<li value="Elective HCI"><a href="#">Electives - HCI</a></li>
</ul>
</div>
<script>
$(".'.$j.' a").click(function(){
$("#'.$j.'").text($(this).text());
});
</script>
</td>
<td>
<button type="button" class="btn btn-primary btn-sm" data-toggle="modal" data-target="#myModal">
Mark attendance
</button>
</td>
</tr>
//THE PHP CODE
Aucun commentaire:
Enregistrer un commentaire