Current File : /home/inlingua/www/sensoriumpsychologists.com/admin/view_student_detail.php |
<?php
include_once('include/include.script.php');
include_once('include/navigation.php');
include_once('../classes/config.php');
$id=$_GET['id'];
$result1=$query->select_where('shristi_student','student_id',$id);
$row1=$result1->fetch_assoc();
$result2=$query->select_where_field('shristi_students_details','student_id',$id,"AND status!=1");
$row2=$result2->fetch_assoc();
$result3=$query->select_where('shristi_students_payment','student_id',$id);
$row3=$result3->fetch_assoc();
$result4=$query->select_where('shristi_franchise','franchise_id',$row1['franchise_id']);
$row4=$result4->fetch_assoc();
?>
<?php
@$ides=$_GET['ides'];
@$ids=$_GET['ids'];
extract($_REQUEST);
if(isset($ides)){
$sql1 = "UPDATE shristi_assignment_result SET status='0' WHERE id='$ids' AND user_id='$id'";
$resultq=$conn->query($sql1);
if($resultq){
$sql = "UPDATE shristi_student SET $ides='1' WHERE student_id='$id'";
$result =$conn->query($sql);
if($result){
$message->success();
echo "<meta http-equiv=\"refresh\" content=\"2;URL=view_student_detail.php?id=$id\">";
}
}
else{
$message->error();
}
}
?>
<div id="main">
<div class="container-fluid">
<div class="page-header">
<div class="pull-left">
<h1>Student Details</h1>
</div>
<div class="pull-right">
<ul class="stats">
<li class='lightred'>
<i class="icon-calendar"></i>
<div class="details">
<span class="big">February 22, 2013</span>
<span>Wednesday, 13:56</span>
</div>
</li>
</ul>
</div>
</div>
<div class="breadcrumbs">
<ul>
<li>
<a href="index.php">Home</a>
<i class="icon-angle-right"></i>
</li>
<li>
<a href="list_student.php">Students details</a>
<i class="icon-angle-right"></i>
</li>
<li>
<a>Student's details</a>
</li>
</ul>
<div class="close-bread">
<a href="#"><i class="icon-remove"></i></a>
</div>
</div>
<div class="row-fluid">
<div class="span12">
<div class="box">
<div class="box-content">
<div class="invoice-info">
<div class="invoice-name">
<?php echo $row1['fname'];?> <?php echo $row1['lname'];?>
</div>
<div class="invoice-from">
<strong>Present Address</strong>
<address><?php echo $row2['p_address'];?></address>
<strong>Communication Address</strong>
<address><?php echo $row2['c_address'];?>
<strong> City: </strong><?php echo $row2['city'];?>
<strong> state :</strong><?php echo $row2['state'];?>
<strong>postal code :</strong><?php echo $row2['p_code'];?>
</address>
Email_id: <?php echo $row1['email']; ?>
</div>
<div class="invoice-infos">
<table>
<tr>
<th>Joining Date:</th>
<td><?php echo $row1['registration_date'];?></td>
</tr>
<tr>
<th>Registration No. </th>
<td><?php echo $row1['registration_no'];?></td>
</tr>
<tr>
<th>Expiray Date:</th>
<td><?php echo $row1['next_end_date'];?></td>
</tr>
</table>
</div>
</div>
<table class="table table-bordered table-striped ">
<thead>
<tr>
<th>Father's Name</th>
<th>Mother's Name</th>
<th>DOB</th>
<th>Gender</th>
<th>Franchise</th>
<th>Course selected</th>
<th>Cource Fees</th>
<th>Cource Batch</th>
</tr>
</thead>
<tbody>
<tr>
<td class='name'><?php echo $row2['father_name'];?></td>
<td class='price'><?php echo $row2['mother_name'];?></td>
<td class='qty'><?php echo $row2['dob'];?></td>
<td class='total'><?php echo $row2['gender'];?></td>
<td class='total'><?php echo $row4['name'];?></td>
<?php
$result4=$query->select_where('shristi_course','courses_id',$row1['courses_id']);
$row4=$result4->fetch_assoc();
?>
<td class='total'><?php echo $row4['name'];?></td>
<td class='total'><?php echo $row4['fee'];?></td>
<td class='total'><?php echo $row1['join_batch'];?>
<?php echo $row1['registration_date'];?></td>
</tr>
<tr>
<td colspan="4"></td>
</tr>
</tbody>
</table>
<table class="table table-bordered table-striped table-invoice">
<thead>
<tr>
<th class='tr'>Qualification</th>
<th class='tr'>Board/University</th>
<th class='tr'>Year of Passing</th>
<th class='tr'>Percentage of Marks</th>
</tr>
</thead>
<tbody>
<tr>
<td class='price'>Matriculation</td>
<td class='price'><?php echo $row2['mboard'];?></td>
<td class='price'><?php echo $row2['myear'];?></td>
<td class='qty'><?php echo $row2['mprecentage'];?></td>
</tr>
<tr>
<td class='price'>Higher Secondary</td>
<td class='price'><?php echo $row2['hboard'];?></td>
<td class='price'><?php echo $row2['hyear'];?></td>
<td class='qty'><?php echo $row2['hprecentage'];?></td>
</tr>
<tr>
<td class='price'>Graduation</td>
<td class='price'><?php echo $row2['gboard'];?></td>
<td class='price'><?php echo $row2['gyear'];?></td>
<td class='qty'><?php echo $row2['gprecentage'];?></td>
</tr>
<tr>
<td class='price'>Other Qualification</td>
<td class='price'><?php echo $row2['oboard'];?></td>
<td class='price'><?php echo $row2['oyear'];?></td>
<td class='qty'><?php echo $row2['oprecentage'];?></td>
</tr>
<tr>
<td colspan="4"></td>
</tr>
</tbody>
</table>
<hr>
<!--assignment result-->
<table class="table table-bordered table-striped ">
<thead>
<tr>
<th>Sn No</th>
<th>Assignment</th>
<th>Right Answer</th>
<th>Wrong Answer</th>
<th>Unanswered</th>
<th>Time</th>
<th>Option</th>
</tr>
</thead>
<tbody>
<?php
$result11=$query->select_where_field('shristi_assignment_result','user_id',$id,"AND status!=1");
$count=$result11->num_rows;
for($i=1;$i<=$count;$i++){
while($row11=$result11->fetch_assoc()){
?>
<tr>
<td class="name"><?php echo ($i+1)?></td>
<td class='name'><?php echo $row11['assignment_id'];?></td>
<td class='qty'><?php echo $row11['right_answer'];?></td>
<td class='total'><?php echo $row11['wrong_answer'];?></td>
<td class='total'><?php echo $row11['unanswered'];?></td>
<td class='total'><?php echo $row11['created_at'];?></td>
<td class='total'>
<a href="view_student_detail.php?id=<?php echo $id;?>&ides=assignment<?php echo $row11['assignment_id']; ?>&ids=<?php echo $row11['id'];?>" class="btn label label-satgreen" onclick="return confirm('sure to Inactive !');">ReActive</a>
</td>
</tr>
<?php $i++; }}?>
<tr>
<td colspan="8"></td>
</tr>
</tbody>
</table>
<?php
$id=$_GET['id'];
$resultss=$query->select_where_field('shristi_final_result','user_id',$id,"AND status !=''"); ?>
<!-- Info boxes -->
<table class="student table table-striped">
<tr>
<td colspan="11"><h4>Final Exam result</h4></td>
</tr>
<tr>
<th>Total Question</th>
<th>Right Answers</th>
<th>Wrong Answers</th>
<th>Total Marks</th>
<th>Total %</th>
</tr>
<?php
while($row=$resultss->fetch_assoc()){
$right_answer = $row['right_answer'];
$wrong_answer = $row['wrong_answer'];
$total_marks = $row['right_answer'];
?>
<tr>
<td><?php
$results12=$query->select_where('shristi_final_test','status','1');
//echo $arow=$results12->num_rows;
echo $arow=50;
?></td>
<td><?php echo $right_answer; ?></td>
<td><?php echo $wrong_answer; ?></td>
<td><?php echo $total_marks; ?></td>
<td><?php
if($total_marks==0){echo "Enable To get Your %";}
else{ $new_width = ($right_answer/ $arow ) * 100;
if($new_width<=50){
echo "<p class='btn btn-danger' style='color:black;'>$new_width</p>";
}else{echo "<p class='btn btn-success' style='color:green;'>$new_width</p>";}
}
?></td>
</tr>
<?php } ?>
</table>
<div class="invoice-payment">
<span>Payment methods</span>
<ul>
<li>
<?php echo $row3['payment_mode'];?>
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<?php include_once('include/footer.php');?>