Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- echo "<script> var students = [[],[]];";
- $students = "";
- for($i=0; $i<$query->rowCount(); $i++) {
- echo "students[$i][0] = " . $result[$i]['studentID'] . ";";
- echo "students[$i][1] = " . $result[$i]['coachID'] . ";";
- echo "students[$i][2] = " . $result[$i]['schoolID'] . ";";
- echo "students[$i][3] = '" . $result[$i]['firstName'] . "';";
- echo "students[$i][4] = '" . $result[$i]['lastName'] . "';";
- echo "students[$i][5] = " . $result[$i]['grade'] . ";";
- $students .= "<option value='$i'>" . $result[$i]['firstName'] ."</option>";
- }
- echo "</script>";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement