</div> <div class="clear"></div> </div> <div class="quest_box"> <form class="form-horizontal" role="form" id='login' method="post" action="result.php"> <?php foreach ($questionArray as $row) { ?> <div id='question<?php echo $questCt; ?> ' class='cont'> <div class="subject">Subject : <?php echo getSubjectName($conn, $row['sub_id']); ?> </div> <div class="question"> <p class='questions' id="qname<?php echo $questCt; ?> "> <div class="quest_num"><?php echo $questCt; ?> </div> <?php echo $row['question']; ?> </p>
while ($row = $mlx->fetch_assoc()) { ?> <div class="grand_quest"> <?php $attempt_id = $row['attempt_id']; $neely = $conn->query("select * from scores where attempt_id='{$attempt_id}' and registration_id='{$registration_id}'"); while ($rows = $neely->fetch_assoc()) { $subject_id = $rows['subject_id']; $total_marks_obtain = $rows['total_marks_obtain']; $total_marks = $rows['total_marks']; $right_per = $total_marks_obtain / $total_marks * 100; ?> <div class="exam_score"> <div class="subject"> <?php echo getSubjectName($conn, $subject_id); ?> <span><?php echo ceil($right_per); ?> %</span> </div> <div class="range"> <div class="percentage sub_1" style="width:<?php echo ceil($right_per); ?> %;"></div> </div> </div> <?php }