Server IP : 2a02:4780:11:1359:0:1d43:a566:2 / Your IP : 216.73.216.161 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/mhischool.in/public_html/admin/../admin/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
<?php include('../link/databaseconnection.php'); session_start(); $lg=$_SESSION['admin']; $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); $rol=$row3['application']; $class=$row3['subject']; $boards=$row3['mediam']; if($class=='FIRST') { $rol1=$id; ?> <?php $lg=$_SESSION['admin']; $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); $rol=$id; $class=$row3['subject']; $board=$row3['mediam']; $sel="select * from six_eightresult where session='$session' and class='$class' and rol='$id'"; $res=mysqli_query($conn,$sel); $row=mysqli_fetch_array($res,MYSQLI_BOTH); $exam=$row['name']; $sel2="select * from six_eightresult where session='$session' and class='$class' and exam='SECOND TERM EXAM' and rol='$id' "; $res2=mysqli_query($conn,$sel2); $row2=mysqli_fetch_array($res2,MYSQLI_BOTH); $sel21="select * from six_eightresult where session='$session' and class='$class' and exam='THIRD TERM EXAM' and rol='$id' "; $res21=mysqli_query($conn,$sel21); $row21=mysqli_fetch_array($res21,MYSQLI_BOTH); ?> <html> <head> <link href="https://cdn.datatables.net/1.10.16/css/jquery.dataTables.min.css" type="text/css" rel="stylesheet"/> <link href="https://cdn.datatables.net/buttons/1.5.1/css/buttons.dataTables.min.css" type="text/css" rel="stylesheet"/> <script src="//code.jquery.com/jquery-1.12.4.js"></script> <script src="https://cdn.datatables.net/1.10.16/js/jquery.dataTables.min.js"></script> <script src="https://cdn.datatables.net/buttons/1.5.1/js/dataTables.buttons.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.flash.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.html5.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.print.min.js"></script> <script> $(document).ready(function(){ $('#example').DataTable({ dom: 'Bfrtip', buttons: ['copy', 'csv', 'excel', 'pdf', 'print'] }); }); </script> <style> #header { height:70px; background-color:red; width:495px; } #logo { height:70px; background-color:green; width:70px; float-left; } #name { height:70px; background-color:yellow; width:420px; float-left; } </style> <style type="text/css" media="print"> @page { size: A4; /* auto is the initial value */ margin: 6mm; /* this affects the margin in the printer settings */ } @media print { jk {position:relative;} } </style> </head> <body> <?php ////FOR THIRD/// ///// ///// FOR SECOND $row2=mysqli_fetch_array($res2,MYSQLI_BOTH); if($row2['mark1']=='Ab'){'0';}else{$row2['mark1'] ;} if($row2['mark2']=='Ab'){'0';}else{$row2['mark2'] ;} if($row2['mark3']=='Ab'){'0';}else{$row2['mark3'] ;} if($row2['mark4']=='Ab'){'0';}else{$row2['mark4'] ;} if($row2['mark5']=='Ab'){'0';}else{$row2['mark5'] ;} $marktotal2=$row2['mark1']+$row2['mark2']+$row2['mark3']+$row2['mark4']+$row2['mark5']; $per2=$marktotal2/0.5; //$per2=$per2*100; //$per=$per1*100; $rol1=$id; //echo $marktotal; ///// FOR SECOND $sel21="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res2=mysqli_query($conn,$sel2); //$row21=mysqli_fetch_array($res21,MYSQLI_BOTH); $sel31="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res31=mysqli_query($conn,$sel31); $row31=mysqli_fetch_array($res31,MYSQLI_BOTH); $sel311="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res311=mysqli_query($conn,$sel311); $sel211="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res211=mysqli_query($conn,$sel211); $sel2111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res2111=mysqli_query($conn,$sel2111); $row2111=mysqli_fetch_array($res2111,MYSQLI_BOTH); while($row311=mysqli_fetch_array($res311,MYSQLI_BOTH)) { if($row311['mark1']=='A'){'0';}else{$row311['mark1'] ;} if($row311['mark2']=='A'){'0';}else{$row311['mark2'] ;} if($row311['mark3']=='A'){'0';}else{$row311['mark3'] ;} if($row311['mark4']=='A'){'0';}else{$row311['mark4'] ;} if($row311['mark5']=='A'){'0';}else{$row311['mark5'] ;} $marktotals=(int)$row311['mark1']+(int)$row311['mark2']+(int)$row311['mark3']+(int)$row311['mark4']+(int)$row311['mark5']; $pers=$marktotals/1.5; //$pers=$pers*100; //ECHO $marktotals; } ///// for fourth term $sel411="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res411=mysqli_query($conn,$sel411); $sel4111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res4111=mysqli_query($conn,$sel4111); $row4111=mysqli_fetch_array($res4111,MYSQLI_BOTH); $row411=mysqli_fetch_array($res411,MYSQLI_BOTH); if($row411['mark1']=='A'){'0';}else{$row411['mark1'] ;} if($row411['mark2']=='A'){'0';}else{$row411['mark2'] ;} if($row411['mark3']=='A'){'0';}else{$row411['mark3'] ;} if($row411['mark4']=='A'){'0';}else{$row411['mark4'] ;} if($row411['mark5']=='A'){'0';}else{$row411['mark5'] ;} $marktotal411=(int)$row411['mark1']+(int)$row411['mark2']+(int)$row411['mark3']+(int)$row411['mark4']+(int)$row411['mark5']; $per411=$marktotal411/2.5; //$per411=$per411*100; //ECHO $marktotals; ///// for fourth term $row211=mysqli_fetch_array($res211,MYSQLI_BOTH); if($row211['mark1']=='A'){'0';}else{$row211['mark1'] ;} if($row211['mark2']=='A'){'0';}else{$row211['mark2'] ;} if($row211['mark3']=='A'){'0';}else{$row211['mark3'] ;} if($row211['mark4']=='A'){'0';}else{$row211['mark4'] ;} if($row211['mark5']=='A'){'0';}else{$row211['mark5'] ;} $marktotal211=(int)$row211['mark1']+(int)$row211['mark2']+(int)$row211['mark3']+(int)$row211['mark4']+(int)$row211['mark5']; $per211=$marktotal211/0.5; //$per211=$per211*100; //echo $marktotal211; $all=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp1=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp=$allp1/5; //$allp=$allp1/16; ?> <center> <?php $rol1=$row1['rol']; $sel5="select *from registration where id='$id' order by id desc"; $res5=mysqli_query($conn,$sel5); $row5=mysqli_fetch_array($res5,MYSQLI_BOTH); $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); $sel1="select * from six_eightresult where session='$session' and class='$class' and exam='FIRST TERM EXAM' and rol='$id'"; $res1=mysqli_query($conn,$sel1); $s=2017; $r=1; $row1=mysqli_fetch_array($res1,MYSQLI_BOTH); if($row1['mark1']=='A'){'0';}else{$row1['mark1'] ;} if($row1['mark2']=='A'){'0';}else{$row1['mark2'] ;} if($row1['mark3']=='A'){'0';}else{$row1['mark3'] ;} if($row1['mark4']=='A'){'0';}else{$row1['mark4'] ;} if($row1['mark5']=='A'){'0';}else{$row1['mark5'] ;} $marktotal=(int)$row1['mark1']+(int)$row1['mark2']+(int)$row1['mark3']+(int)$row1['mark4']+(int)$row1['mark5']; $per=$marktotal/0.5; ?> <table frame="border" height="10%" width="100%" id="example"> <tr> <td align="center" COLSPAN="5"><img src="../images/mhi.png" style="width:100%" height="140px" width="100%"/></td> </tr> </table> <table border="1px" width="100%" cellspacing="0"> <tr align="center"> <td><h4>Class: <?php echo $row3['subject'];?></h4></td><td colspan="2"><h4>THIRD TERM EXAM-<?php echo $row3['session'];?></h4></td><td ><h4>Roll Number: <?php echo $row3['id'];?></h4></td> </tr> <tr align=""> <td>Name</td><td colspan="2"><p><?php echo $row3['name'];?></p></td><td rowspan="4"> <center><img src="../code/img/<?php echo $row3['picture'];?>" height="80px" width="100px"/></center></td> </tr> <tr align=""> <td>Father Name</td><td colspan="2"><p><?php echo $row3['fname'];?></p></td> </tr> <tr align=""> <td>Mother Name</td><td colspan="2"><p><?php echo $row3['mname'];?></p></td> </tr> <tr align=""> <td>Date Of Birth</td><td colspan="2"><p><?php echo $row3['dob'];?></p></td> </tr> <tr align="center"> <td colspan="5"><h3>MARKS</h3></td> </tr> <table cellspacing="0" border="1px" width="100%"> <tr align="center" style="font-weight:bold"> <td rowspan="2">SUBJECT</td><td colspan="2">FIRST TERM EXAM.</td><td colspan="2">SECOND TERM EXAM.</td><td colspan="2">THIRD TERM EXAM.</td><td colspan="2">ANNUAL EXAM.</td> </tr> <tr align="center"> <td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td> </tr> <tr align="center"> <td style="text-align:left">HINDI</td><td>10</td><td><?php echo $row1['mark1'];?></td><td>30</td><td><?php echo $row31['mark1'];?></td><td>10</td><td STYLE=''><?php echo $row2111['mark1'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark1'];?></td> </tr> <tr align="center"> <td style="text-align:left">ENGLISH</td><td>10</td><td><?php echo $row1['mark2'];?></td><td>30</td><td><?php echo $row31['mark2'];?></td><td>10</td><td><?php echo $row2111['mark2'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark2'];?></td> </tr> <tr align="center"> <td style="text-align:left">MATHS</td><td>10</td><td><?php echo $row1['mark3'];?></td><td>30</td><td><?php echo $row31['mark3'];?></td><td>10</td><td><?php echo $row2111['mark3'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark3'];?></td> </tr> <tr align="center"> <td style="text-align:left">SCIENCE</td><td>10</td><td><?php echo $row1['mark4'];?></td><td>30</td><td><?php echo $row31['mark4'];?></td><td>10</td><td><?php echo $row2111['mark4'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark4'];?></td> </tr> <tr align="center"> <td style="text-align:left">ART</td><td>10</td><td><?php echo $row1['mark5'];?></td><td>30</td><td><?php echo $row31['mark5'];?></td><td>10</td><td><?php echo $row2111['mark5'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark5'];?></td> </tr> <tr align="center"> <td style="text-align:left">URDU</td><td>GRADE</td><td>A1</td><td>GRADE</td><td>A1</td><td>GRADE</td><td>A1</td><td>GRADE</td><td STYLE=''>A1</td> </tr> <tr align="center"> <td style="text-align:left">ARABI</td><td>GRADE</td><td>A1</td><td>GRADE</td><td>A1</td><td>GRADE</td><td>A1</td><td>GRADE</td><td STYLE=''>A1</td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotals;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal211;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal411;?></td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$pers",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per211",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per411",0,5).'%';?></td> </tr> <tr> <td colspan="4" align="center"><h4><br/>ALL TOTAL RESULT<br/><br/>ALL TOTAL PER<br/><br/>DIVISION</h4><br/></td><td colspan="6" align="center"><h4 style="color:red"><?php echo $all.'/500';?><BR/><br/><?php echo substr("$allp",0,5).'%';?> <BR/><BR/><?PHP if($allp>=33 ) { if($allp>=33 and $allp<=45) { echo "THIRD"; } else if($allp>45 and $allp<60) { echo "SECOND"; } else if($allp=60 and $allp<=100) { echo "FIRST"; } } ELSE { echo "NO OBTAIN"; } ?> </h4></td> </tr> <tr> <td colspan="4" align="center"><h4>Guardian's Signature</h4><br/><br/><br/></td><td colspan="5" align="center"><h4>Principal's Signature</h4><br/><br/><br/></td> </tr> <tr align="center"> <td>Note:</td><td colspan="8"><i>Please make Signature Principal and Guardian in Space.</i></td> </tr> </table> <center><img src="../images/mhi mark1.png" id="jk" style="position:relative;height:500px;width:100%;margin-top:-1800px;z-index:-1;"/></center> <?php ?> </body> </html> <?php } if($class=='SECOND' or $class=='THIRD' or $class=='FOURTH' or $class=='FIFTH') { ?> <?php error_reporting(0); $board='CBSE BOARD'; $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); //echo $id; $sel="select * from six_eightresult where session='$session' and rol='$id'"; $res=mysqli_query($conn,$sel); $row=mysqli_fetch_array($res,MYSQLI_BOTH); $exam=$row['name']; $sel1="select * from six_eightresult where session='$session' and rol='$id' and exam='FIRST TERM EXAM'"; $res1=mysqli_query($conn,$sel1); $sel2="select * from six_eightresult where session='$session' and rol='$id' and exam='SECOND TERM EXAM' "; $res2=mysqli_query($conn,$sel2); $sel21="select * from six_eightresult where session='$session' and rol='$id' and exam='THIRD TERM EXAM' "; $res21=mysqli_query($conn,$sel21); ?> <html> <head> <link href="https://cdn.datatables.net/1.10.16/css/jquery.dataTables.min.css" type="text/css" rel="stylesheet"/> <link href="https://cdn.datatables.net/buttons/1.5.1/css/buttons.dataTables.min.css" type="text/css" rel="stylesheet"/> <script src="//code.jquery.com/jquery-1.12.4.js"></script> <script src="https://cdn.datatables.net/1.10.16/js/jquery.dataTables.min.js"></script> <script src="https://cdn.datatables.net/buttons/1.5.1/js/dataTables.buttons.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.flash.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.html5.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.print.min.js"></script> <script> $(document).ready(function(){ $('#example').DataTable({ dom: 'Bfrtip', buttons: ['copy', 'csv', 'excel', 'pdf', 'print'] }); }); </script> <style> #header { height:70px; background-color:red; width:495px; } #logo { height:70px; background-color:green; width:70px; float-left; } #name { height:70px; background-color:yellow; width:420px; float-left; } </style> <style type="text/css" media="print"> @page { size: A4; /* auto is the initial value */ margin: 6mm; /* this affects the margin in the printer settings */ } @media print { jk {position:relative;} } </style> </head> <body> <?php ////FOR THIRD/// ///// ///// FOR SECOND $row2=mysqli_fetch_array($res2,MYSQLI_BOTH); if($row2['mark1']=='A'){'0';}else{$row2['mark1'] ;} if($row2['mark2']=='A'){'0';}else{$row2['mark2'] ;} if($row2['mark3']=='A'){'0';}else{$row2['mark3'] ;} if($row2['mark4']=='A'){'0';}else{$row2['mark4'] ;} if($row2['mark5']=='A'){'0';}else{$row2['mark5'] ;} if($row2['mark10']=='A'){'0';}else{$row2['mark10'] ;} if($row2['mark7']=='A'){'0';}else{$row2['mark7'] ;} if($row2['mark8']=='A'){'0';}else{$row2['mark8'] ;} if($row2['mark9']=='A'){'0';}else{$row2['mark9'] ;} //echo $row2['mark1']; $marktotal2=(int)$row2['mark1']+(int)$row2['mark2']+(int)$row2['mark3']+(int)$row2['mark4']+(int)$row2['mark5']+(int)$row2['mark7']+(int)$row2['mark8']; $per2=$marktotal2/0.7; $per2=$per2*100; $s=2017; $r=1; $row1=mysqli_fetch_array($res1,MYSQLI_BOTH); if($row1['mark1']=='A'){'0';}else{$row1['mark1'] ;} if($row1['mark2']=='A'){'0';}else{$row1['mark2'] ;} if($row1['mark3']=='A'){'0';}else{$row1['mark3'] ;} if($row1['mark4']=='A'){'0';}else{$row1['mark4'] ;} if($row1['mark5']=='A'){'0';}else{$row1['mark5'] ;} if($row1['mark10']=='A'){'0';}else{$row1['mark10'] ;} if($row1['mark7']=='A'){'0';}else{$row1['mark7'] ;} if($row1['mark8']=='A'){'0';}else{$row1['mark8'] ;} if($row1['mark9']=='A'){'0';}else{$row1['mark9'] ;} $marktotal=(int)$row1['mark1']+(int)$row1['mark2']+(int)$row1['mark3']+(int)$row1['mark4']+(int)$row1['mark5']+(int)$row1['mark8']; $per1=$marktotal/0.6; $per=$per1; $rol1=$row1['rol']; //echo $marktotal; ///// FOR SECOND $rol1=$id; $sel21="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res2=mysqli_query($conn,$sel2); //$row21=mysqli_fetch_array($res21,MYSQLI_BOTH); $sel31="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res31=mysqli_query($conn,$sel31); $row31=mysqli_fetch_array($res31,MYSQLI_BOTH); $sel311="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res311=mysqli_query($conn,$sel311); $sel211="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res211=mysqli_query($conn,$sel211); $sel2111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res2111=mysqli_query($conn,$sel2111); $row2111=mysqli_fetch_array($res2111,MYSQLI_BOTH); $row311=mysqli_fetch_array($res311,MYSQLI_BOTH); if($row311['mark1']=='Ab'){'0';}else{$row311['mark1'] ;} if($row311['mark2']=='Ab'){'0';}else{$row311['mark2'] ;} if($row311['mark3']=='Ab'){'0';}else{$row311['mark3'] ;} if($row311['mark4']=='Ab'){'0';}else{$row311['mark4'] ;} if($row311['mark5']=='Ab'){'0';}else{$row311['mark5'] ;} if($row311){'0';}else{$row311['mark10'] ;} if($row311){'0';}else{$row311['mark7'] ;} if($row311){'0';}else{$row311['mark8'] ;} if($row311){'0';}else{$row311['mark9'] ;} $marktotals=(int)$row311['mark1']+(int)$row311['mark2']+(int)$row311['mark3']+(int)$row311['mark4']+(int)$row311['mark5']+(int)$row311['mark8']; $pers=$marktotals/1.8; $pers=$pers; //ECHO $marktotals; ///// for fourth term $sel411="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res411=mysqli_query($conn,$sel411); $sel4111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res4111=mysqli_query($conn,$sel4111); $row4111=mysqli_fetch_array($res4111,MYSQLI_BOTH); $row411=mysqli_fetch_array($res411,MYSQLI_BOTH); if($row411['mark1']=='A'){'0';}else{$row411['mark1'] ;} if($row411['mark2']=='A'){'0';}else{$row411['mark2'] ;} if($row411['mark3']=='A'){'0';}else{$row411['mark3'] ;} if($row411['mark4']=='A'){'0';}else{$row411['mark4'] ;} if($row411['mark5']=='A'){'0';}else{$row411['mark5'] ;} if($row411['mark10']=='A'){'0';}else{$row411['mark10'] ;} if($row411['mark7']=='A'){'0';}else{$row411['mark7'] ;} if($row411['mark8']=='A'){'0';}else{$row411['mark8'] ;} if($row411['mark9']=='A'){'0';}else{$row411['mark9'] ;} $marktotal411=(int)$row411['mark1']+(int)$row411['mark2']+(int)$row411['mark3']+(int)$row411['mark4']+(int)$row411['mark5']+(int)$row411['mark8']; $per411=$marktotal411/3; $per411=$per411; //ECHO $marktotals; ///// for fourth term $row211=mysqli_fetch_array($res211,MYSQLI_BOTH); if($row211['mark1']=='A'){'0';}else{$row211['mark1'] ;} if($row211['mark2']=='A'){'0';}else{$row211['mark2'] ;} if($row211['mark3']=='A'){'0';}else{$row211['mark3'] ;} if($row211['mark4']=='A'){'0';}else{$row211['mark4'] ;} if($row211['mark5']=='A'){'0';}else{$row211['mark5'] ;} if($row211['mark10']=='A'){'0';}else{$row211['mark10'] ;} if($row211['mark7']=='A'){'0';}else{$row211['mark7'] ;} if($row211['mark8']=='A'){'0';}else{$row211['mark8'] ;} if($row211['mark9']=='A'){'0';}else{$row211['mark9'] ;} $marktotal211=(int)$row211['mark1']+(int)$row211['mark2']+(int)$row211['mark3']+(int)$row211['mark4']+(int)$row211['mark5']+(int)$row211['mark8']; $per211=$marktotal211/0.6; $per211=$per211; //echo $marktotal211; $all=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp1=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp=$allp1/6; //$allp=$allp1/16; ?> <center> <table frame="border" height="10%" width="100%" id="example"> <tr> <td align="center" COLSPAN="5"><img src="../images/mhi.png" style="width:100%" height="140px" width="100%"/></td> </tr> </table> <table border="1px" width="100%" cellspacing="0"> <tr align="center"> <td><h4>Class: <?php echo $row3['subject'];?></h4></td><td colspan="2"><h4>ANNUAL EXAM-<?php echo $row3['session'];?></h4></td><td ><h4>Roll Number: <?php echo $row3['id'];?></h4></td> </tr> <tr align=""> <td>Name</td><td colspan="2"><p><?php echo $row3['name'];?></p></td><td rowspan="4"> <?php $rol1=$row1['rol']; $sel5="select *from registration where id='$rol1' order by id desc"; $res5=mysqli_query($conn,$sel5); $row5=mysqli_fetch_array($res5,MYSQLI_BOTH); ?> <center><img src="../code/img/<?php echo $row3['picture'];?>" height="80px" width="100px"/></center></td> </tr> <tr align=""> <td>Father Name</td><td colspan="2"><p><?php echo $row3['fname'];?></p></td> </tr> <tr align=""> <td>Mother Name</td><td colspan="2"><p><?php echo $row3['mname'];?></p></td> </tr> <tr align=""> <td>Date Of Birth</td><td colspan="2"><p><?php echo $row3['dob'];?></p></td> </tr> <tr align="center"> <td colspan="5"><h3>MARKS</h3></td> </tr> <table cellspacing="0" border="1px" width="100%"> <tr align="center" style="font-weight:bold"> <td rowspan="2">SUBJECT</td><td colspan="2">FIRST TERM EXAM.</td><td colspan="2">SECOND TERM EXAM.</td><td colspan="2">THIRD TERM EXAM.</td><td colspan="2">ANNUAL EXAM.</td> </tr> <tr align="center"> <td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td> </tr> <tr align="center"> <td style="text-align:left">HINDI</td><td>10</td><td><?php echo $row1['mark1'];?></td><td>30</td><td><?php echo $row31['mark1'];?></td><td>10</td><td STYLE=''><?php echo $row2111['mark1'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark1'];?></td> </tr> <tr align="center"> <td style="text-align:left">ENGLISH</td><td>10</td><td><?php echo $row1['mark2'];?></td><td>30</td><td><?php echo $row31['mark2'];?></td><td>10</td><td><?php echo $row2111['mark2'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark2'];?></td> </tr> <tr align="center"> <td style="text-align:left">MATHS</td><td>10</td><td><?php echo $row1['mark3'];?></td><td>30</td><td><?php echo $row31['mark3'];?></td><td>10</td><td><?php echo $row2111['mark3'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark3'];?></td> </tr> <tr align="center"> <td style="text-align:left">SCIENCE</td><td>10</td><td><?php echo $row1['mark4'];?></td><td>30</td><td><?php echo $row31['mark4'];?></td><td>10</td><td><?php echo $row2111['mark4'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark4'];?></td> </tr> <tr align="center"> <td style="text-align:left">ART</td><td>10</td><td><?php echo $row1['mark5'];?></td><td>30</td><td><?php echo $row31['mark5'];?></td><td>10</td><td><?php echo $row2111['mark5'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark5'];?></td> </tr> <tr align="center"> <td style="text-align:left">SOCI STU</td><td>10</td><td><?php echo $row1['mark8'];?></td><td>30</td><td><?php echo $row31['mark8'];?></td><td>10</td><td><?php echo $row2111['mark8'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark8'];?></td> </tr> <tr align="center"> <td style="text-align:left">URDU</td><td>GRADE</td><td><?php echo $row1['mark6'];?></td><td>GRADE</td><td><?php echo $row31['mark6'];?></td><td>GRADE</td><td><?php echo $row2111['mark6'];?></td><td>GRADE</td><td STYLE=''><?php echo $row2111['mark6'];?></td> </tr> <tr align="center"> <td style="text-align:left">SANSKRIT</td><td>GRADE</td><td><?php echo $row1['mark12'];?></td><td>GRADE</td><td><?php echo $row31['mark12'];?></td><td>GRADE</td><td><?php echo $row2111['mark12'];?></td><td>GRADE</td><td STYLE=''><?php echo $row4111['mark12'];?></td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotals;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal211;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal411;?></td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$pers",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per211",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per411",0,5).'%';?></td> </tr> <tr> <td colspan="4" align="center"><h4><br/>ALL TOTAL RESULT<br/><br/>ALL TOTAL PER<br/><br/>DIVISION</h4><br/></td><td colspan="6" align="center"><h4 style="color:red"><?php echo $all.'/600';?><BR/><br/><?php echo substr("$allp",0,5).'%';?> <BR/><BR/><?PHP if($allp>=33 ) { if($allp>=33 and $allp<=45) { echo "THIRD"; } else if($allp>45 and $allp<60) { echo "SECOND"; } else if($allp=60 and $allp<=100) { echo "FIRST"; } } ELSE { echo "NO OBTAIN"; } ?> </h4></td> </tr> <tr> <td colspan="4" align="center"><h4>Guardian's Signature</h4><br/><br/><br/></td><td colspan="5" align="center"><h4>Principal's Signature</h4><br/><br/><br/></td> </tr> <tr align="center"> <td>Note:</td><td colspan="8"><i>Please make Signature Principal and Guardian in Space.</i></td> </tr> </table> <center><img src="../images/mhi mark1.png" id="jk" style="position:relative;height:500px;width:100%;margin-top:-1800px;z-index:-1;"/></center> <?php ?><br/><br/><br/><br/><BR/><BR/><?php ?> </body> </html> <?php } ?> <?php if($class=='LKG' or $class=='UKG' or $class=='PLAY GROUP' or $class=='NURSERY') { $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); ?> <?php $lg=$_SESSION['admin']; $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); $rol=$row3['application']; $rol=$row3['application']; $class=$row3['subject']; $board=$row3['mediam']; $rol1=$id; $sel="select * from six_eightresult where session='$session' and rol='$rol1' and class='$class'"; $res=mysqli_query($conn,$sel); $row=mysqli_fetch_array($res,MYSQLI_BOTH); $exam=$row['name']; $sel1="select * from six_eightresult where session='$session' and rol='$rol1' and class='$class' and exam='FIRST TERM EXAM'"; $res1=mysqli_query($conn,$sel1); $sel2="select * from six_eightresult where session='$session' and rol='$rol1' and class='$class' and exam='SECOND TERM EXAM'"; $res2=mysqli_query($conn,$sel2); $sel21="select * from six_eightresult where session='$session' and rol='$rol1' and class='$class' and exam='THIRD TERM EXAM'"; $res21=mysqli_query($conn,$sel21); $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); $rol=$row3['application']; ?> <html> <head> <link href="https://cdn.datatables.net/1.10.16/css/jquery.dataTables.min.css" type="text/css" rel="stylesheet"/> <link href="https://cdn.datatables.net/buttons/1.5.1/css/buttons.dataTables.min.css" type="text/css" rel="stylesheet"/> <script src="//code.jquery.com/jquery-1.12.4.js"></script> <script src="https://cdn.datatables.net/1.10.16/js/jquery.dataTables.min.js"></script> <script src="https://cdn.datatables.net/buttons/1.5.1/js/dataTables.buttons.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.flash.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.html5.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.print.min.js"></script> <script> $(document).ready(function(){ $('#example').DataTable({ dom: 'Bfrtip', buttons: ['copy', 'csv', 'excel', 'pdf', 'print'] }); }); </script> <style> #header { height:70px; background-color:red; width:495px; } #logo { height:70px; background-color:green; width:70px; float-left; } #name { height:70px; background-color:yellow; width:420px; float-left; } </style> <style type="text/css" media="print"> @page { size: A4; /* auto is the initial value */ margin: 6mm; /* this affects the margin in the printer settings */ } @media print { jk {position:relative;} } </style> </head> <body> <?php ////FOR THIRD/// ///// ///// FOR SECOND $row2=mysqli_fetch_array($res2,MYSQLI_BOTH); if($row2['mark1']=='Ab'){'0';}else{$row2['mark1'] ;} if($row2['mark2']=='Ab'){'0';}else{$row2['mark2'] ;} if($row2['mark3']=='Ab'){'0';}else{$row2['mark3'] ;} if($row2['mark5']=='Ab'){'0';}else{$row2['mark5'] ;} $marktotal2=(int)$row2['mark1']+(int)$row2['mark2']+(int)$row2['mark3']+(int)$row2['mark5']; $per2=$marktotal2/0.4; $per2=$per2; $s=2017; $r=1; $row1=mysqli_fetch_array($res1,MYSQLI_BOTH); if($row1['mark1']=='A'){'0';}else{$row1['mark1'] ;} if($row1['mark2']=='A'){'0';}else{$row1['mark2'] ;} if($row1['mark3']=='A'){'0';}else{$row1['mark3'] ;} if($row1['mark4']=='A'){'0';}else{$row1['mark4'] ;} if($row1['mark5']=='A'){'0';}else{$row1['mark5'] ;} $marktotal=(int)$row1['mark1']+(int)$row1['mark2']+(int)$row1['mark3']+(int)$row1['mark5']; $per1=$marktotal/0.4; $per=$per1; $rol1=$row1['rol']; //echo $marktotal; ///// FOR SECOND $sel21="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res2=mysqli_query($conn,$sel2); //$row21=mysqli_fetch_array($res21,MYSQLI_BOTH); $sel31="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res31=mysqli_query($conn,$sel31); $row31=mysqli_fetch_array($res31,MYSQLI_BOTH); $sel311="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res311=mysqli_query($conn,$sel311); $sel211="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res211=mysqli_query($conn,$sel211); $sel2111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res2111=mysqli_query($conn,$sel2111); $row2111=mysqli_fetch_array($res2111,MYSQLI_BOTH); $row311=mysqli_fetch_array($res311,MYSQLI_BOTH); if($row311['mark1']=='A'){'0';}else{$row311['mark1'] ;} if($row311['mark2']=='A'){'0';}else{$row311['mark2'] ;} if($row311['mark3']=='A'){'0';}else{$row311['mark3'] ;} if($row311['mark4']=='A'){'0';}else{$row311['mark4'] ;} if($row311['mark5']=='A'){'0';}else{$row311['mark5'] ;} $marktotals=(int)$row311['mark1']+(int)$row311['mark2']+(int)$row311['mark3']+(int)$row311['mark5']; $pers=$marktotals/1.2; $pers=$pers; //ECHO $marktotals; ///// for fourth term $sel411="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res411=mysqli_query($conn,$sel411); $sel4111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res4111=mysqli_query($conn,$sel4111); $row4111=mysqli_fetch_array($res4111,MYSQLI_BOTH); $row411=mysqli_fetch_array($res411,MYSQLI_BOTH); if($row411['mark1']=='A'){'0';}else{$row411['mark1'] ;} if($row411['mark2']=='A'){'0';}else{$row411['mark2'] ;} if($row411['mark3']=='A'){'0';}else{$row411['mark3'] ;} if($row411['mark4']=='A'){'0';}else{$row411['mark4'] ;} if($row411['mark5']=='A'){'0';}else{$row411['mark5'] ;} $marktotal411=(int)$row411['mark1']+(int)$row411['mark2']+(int)$row411['mark3']+(int)$row411['mark5']; $per411=$marktotal411/2; $per411=$per411; //ECHO $marktotals; ///// for fourth term $row211=mysqli_fetch_array($res211,MYSQLI_BOTH); if($row211['mark1']=='A'){'0';}else{$row211['mark1'] ;} if($row211['mark2']=='A'){'0';}else{$row211['mark2'] ;} if($row211['mark3']=='A'){'0';}else{$row211['mark3'] ;} if($row211['mark4']=='A'){'0';}else{$row211['mark4'] ;} if($row211['mark5']=='A'){'0';}else{$row211['mark5'] ;} $marktotal211=(int)$row211['mark1']+(int)$row211['mark2']+(int)$row211['mark3']+(int)$row211['mark5']; $per211=$marktotal211/0.4; $per211=$per211; //echo $marktotal211; $all=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp1=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp=$allp1/4; //$allp=$allp1/16; ?> <center> <table frame="border" height="10%" width="100%" id="example"> <tr> <td align="center" COLSPAN="5"><img src="../images/mhi.png" style="width:100%" height="140px" width="100%"/></td> </tr> </table> <table border="1px" width="100%" cellspacing="0"> <tr align="center"> <td><h4>Class: <?php echo $row3['subject'];?></h4></td><td colspan="2"><h4>THIRD TERM EXAM-<?php echo $row3['session'];?></h4></td><td ><h4>Roll Number: <?php echo $row3['id'];?></h4></td> </tr> <tr align=""> <td>Name</td><td colspan="2"><p><?php echo $row3['name'];?></p></td><td rowspan="4"> <?php $rol1=$row1['rol']; $sel5="select *from registration where id='$rol1' order by id desc"; $res5=mysqli_query($conn,$sel5); $row5=mysqli_fetch_array($res5,MYSQLI_BOTH); $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); ?> <center><img src="../code/img/<?php echo $row3['picture'];?>" height="80px" width="100px"/></center></td> </tr> <tr align=""> <td>Father Name</td><td colspan="2"><p><?php echo $row3['fname'];?></p></td> </tr> <tr align=""> <td>Mother Name</td><td colspan="2"><p><?php echo $row3['mname'];?></p></td> </tr> <tr align=""> <td>Date Of Birth</td><td colspan="2"><p><?php echo $row3['dob'];?></p></td> </tr> <tr align="center"> <td colspan="5"><h3>MARKS</h3></td> </tr> <table cellspacing="0" border="1px" width="100%"> <tr align="center" style="font-weight:bold"> <td rowspan="2">SUBJECT</td><td colspan="2">FIRST TERM EXAM.</td><td colspan="2">SECOND TERM EXAM.</td><td colspan="2">THIRD TERM EXAM.</td><td colspan="2">ANNUAL EXAM.</td> </tr> <tr align="center"> <td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td> </tr> <tr align="center"> <td style="text-align:left">HINDI</td><td>10</td><td><?php echo $row1['mark1'];?></td><td>30</td><td><?php echo $row31['mark1'];?></td><td>10</td><td STYLE=''><?php echo $row2111['mark1'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark1'];?></td> </tr> <tr align="center"> <td style="text-align:left">ENGLISH</td><td>10</td><td><?php echo $row1['mark2'];?></td><td>30</td><td><?php echo $row31['mark2'];?></td><td>10</td><td><?php echo $row2111['mark2'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark2'];?></td> </tr> <tr align="center"> <td style="text-align:left">MATHS</td><td>10</td><td><?php echo $row1['mark3'];?></td><td>30</td><td><?php echo $row31['mark3'];?></td><td>10</td><td><?php echo $row2111['mark3'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark3'];?></td> </tr> <tr align="center"> <td style="text-align:left">ART</td><td>10</td><td><?php echo $row1['mark5'];?></td><td>30</td><td><?php echo $row31['mark5'];?></td><td>10</td><td><?php echo $row2111['mark5'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark5'];?></td> </tr> <tr align="center"> <td style="text-align:left">URDU</td><td>GRADE</td><td><?php echo $row1['mark6'];?></td><td>GRADE</td><td><?php echo $row31['mark6'];?></td><td>GRADE</td><td><?php echo $row2111['mark6'];?></td><td>GRADE</td><td STYLE=''><?php echo $row2111['mark6'];?></td> </tr> <tr align="center"> <td style="text-align:left">ARABI</td><td>GRADE</td><td><?php echo $row1['mark7'];?></td><td>GRADE</td><td><?php echo $row31['mark7'];?></td><td>GRADE</td><td><?php echo $row2111['mark7'];?></td><td>GRADE</td><td STYLE=''><?php echo $row4111['mark7'];?></td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotals;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal211;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal411;?></td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$pers",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per211",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per411",0,5).'%';?></td> </tr> <tr> <td colspan="4" align="center"><h4><br/>ALL TOTAL RESULT<br/><br/>ALL TOTAL PER<br/><br/>DIVISION</h4><br/></td><td colspan="6" align="center"><h4 style="color:red"><?php echo $all.'/400';?><BR/><br/><?php echo substr("$allp",0,5 ).'%';?> <BR/><BR/><?PHP if($allp>=33 ) { if($allp>=33 and $allp<=45) { echo "THIRD"; } else if($allp>45 and $allp<60) { echo "SECOND"; } else if($allp=60 and $allp<=100) { echo "FIRST"; } } ELSE { echo "NO OBTAIN"; } ?> </h4></td> </tr> <tr> <td colspan="4" align="center"><h4>Guardian's Signature</h4><br/><br/><br/></td><td colspan="5" align="center"><h4>Principal's Signature</h4><br/><br/><br/></td> </tr> <tr align="center"> <td>Note:</td><td colspan="8"><i>Please make Signature Principal and Guardian in Space.</i></td> </tr> </table> <center><img src="../images/mhi mark1.png" id="jk" style="position:relative;height:500px;width:100%;margin-top:-1800px;z-index:-1;"/></center> <?php ?> </body> </html> <?php } ?> <?php if($class=='SIXTH' or $class=='SEVENTH' or $class=='EIGHTH') { $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); ?> <?php $lg=$_SESSION['admin']; $id=$_REQUEST['id']; $session=$_REQUEST['session']; $sel3="select *from registration where id='$id' "; $res3=mysqli_query($conn,$sel3); $row3=mysqli_fetch_array($res3,MYSQLI_BOTH); $rol=$row3['application']; $class=$row3['subject']; $board=$row3['mediam']; $rol1=$id; $sel="select * from six_eightresult where session='$session' and class='$class' and rol='$rol1'"; $res=mysqli_query($conn,$sel); $row=mysqli_fetch_array($res,MYSQLI_BOTH); $exam=$row['name']; $sel1="select * from six_eightresult where session='$session' and class='$class' and exam='FIRST TERM EXAM' and rol='$id' "; $res1=mysqli_query($conn,$sel1); $sel2="select * from six_eightresult where session='$session' and class='$class' and exam='FIRST TERM EXAM' and rol='$id' "; $res2=mysqli_query($conn,$sel2); $sel21="select * from six_eightresult where session='$session' and class='$class' and exam='FIRST TERM EXAM' and rol='$id' "; $res21=mysqli_query($conn,$sel21); ?> <html> <head> <link href="https://cdn.datatables.net/1.10.16/css/jquery.dataTables.min.css" type="text/css" rel="stylesheet"/> <link href="https://cdn.datatables.net/buttons/1.5.1/css/buttons.dataTables.min.css" type="text/css" rel="stylesheet"/> <script src="//code.jquery.com/jquery-1.12.4.js"></script> <script src="https://cdn.datatables.net/1.10.16/js/jquery.dataTables.min.js"></script> <script src="https://cdn.datatables.net/buttons/1.5.1/js/dataTables.buttons.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.flash.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.html5.min.js"></script> <script src="//cdn.datatables.net/buttons/1.5.1/js/buttons.print.min.js"></script> <script> $(document).ready(function(){ $('#example').DataTable({ dom: 'Bfrtip', buttons: ['copy', 'csv', 'excel', 'pdf', 'print'] }); }); </script> <style> #header { height:70px; background-color:red; width:495px; } #logo { height:70px; background-color:green; width:70px; float-left; } #name { height:70px; background-color:yellow; width:420px; float-left; } </style> <style type="text/css" media="print"> @page { size: A4; /* auto is the initial value */ margin: 6mm; /* this affects the margin in the printer settings */ } @media print { jk {position:relative;} } </style> </head> <body> <?php ////FOR THIRD/// ///// ///// FOR SECOND $row2=mysqli_fetch_array($res2,MYSQLI_BOTH); if($row2['mark1']=='A'){'0';}else{$row2['mark1'] ;} if($row2['mark2']=='A'){'0';}else{$row2['mark2'] ;} if($row2['mark3']=='A'){'0';}else{$row2['mark3'] ;} if($row2['mark4']=='A'){'0';}else{$row2['mark4'] ;} if($row2['mark5']=='A'){'0';}else{$row2['mark5'] ;} if($row2['mark10']=='A'){'0';}else{$row2['mark10'] ;} if($row2['mark6']=='A'){'0';}else{$row2['mark6'] ;} if($row2['mark8']=='A'){'0';}else{$row2['mark8'] ;} if($row2['mark9']=='A'){'0';}else{$row2['mark9'] ;} if($row2['mark11']=='A'){'0';}else{$row2['mark11'] ;} $marktotal2=(int)$row2['mark1']+(int)$row2['mark2']+(int)$row2['mark3']+(int)$row2['mark4']+(int)$row2['mark5']+(int)$row2['mark9']+(int)$row2['mark11']; $per2=$marktotal2/0.7; $per2=$per2; $s=2017; $r=1; $row1=mysqli_fetch_array($res1,MYSQLI_BOTH); if($row1['mark1']=='A'){'0';}else{$row1['mark1'] ;} if($row1['mark2']=='A'){'0';}else{$row1['mark2'] ;} if($row1['mark3']=='A'){'0';}else{$row1['mark3'] ;} if($row1['mark4']=='A'){'0';}else{$row1['mark4'] ;} if($row1['mark5']=='A'){'0';}else{$row1['mark5'] ;} if($row1['mark10']=='A'){'0';}else{$row1['mark10'] ;} if($row1['mark6']=='A'){'0';}else{$row1['mark6'] ;} if($row1['mark8']=='A'){'0';}else{$row1['mark8'] ;} if($row1['mark9']=='A'){'0';}else{$row1['mark9'] ;} if($row1['mark11']=='A'){'0';}else{$row1['mark11'] ;} $marktotal=(int)$row1['mark1']+(int)$row1['mark2']+(int)$row1['mark3']+(int)$row1['mark4']+(int)$row1['mark5']+(int)$row1['mark9']+(int)$row1['mark11']; $per1=$marktotal/0.7; $per=$per1; $rol1=$row1['rol']; //echo $marktotal; ///// FOR SECOND $sel21="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res2=mysqli_query($conn,$sel2); //$row21=mysqli_fetch_array($res21,MYSQLI_BOTH); $sel31="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res31=mysqli_query($conn,$sel31); $row31=mysqli_fetch_array($res31,MYSQLI_BOTH); $sel311="select * from six_eightresult where session='$session' and rol='$rol1' and exam='SECOND TERM EXAM' "; $res311=mysqli_query($conn,$sel311); $sel211="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res211=mysqli_query($conn,$sel211); $sel2111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='THIRD TERM EXAM' "; $res2111=mysqli_query($conn,$sel2111); $row2111=mysqli_fetch_array($res2111,MYSQLI_BOTH); $row311=mysqli_fetch_array($res311,MYSQLI_BOTH); if($row311['mark1']=='Ab'){'0';}else{$row311['mark1'] ;} if($row311['mark2']=='Ab'){'0';}else{$row311['mark2'] ;} if($row311['mark3']=='Ab'){'0';}else{$row311['mark3'] ;} if($row311['mark4']=='Ab'){'0';}else{$row311['mark4'] ;} if($row311['mark5']=='Ab'){'0';}else{$row311['mark5'] ;} if($row311){'0';}else{$row311['mark10'] ;} if($row311){'0';}else{$row311['mark6'] ;} if($row311){'0';}else{$row311['mark8'] ;} if($row311){'0';}else{$row311['mark9'] ;} if($row211['mark11']=='A'){'0';}else{$row211['mark11'] ;} $marktotals=(int)$row311['mark1']+(int)$row311['mark2']+(int)$row311['mark3']+(int)$row311['mark4']+(int)$row311['mark5']+(int)$row311['mark9']+(int)$row311['mark11']; $pers=$marktotals/2.1; $pers=$pers; //ECHO $marktotals; ///// for fourth term $sel411="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res411=mysqli_query($conn,$sel411); $sel4111="select * from six_eightresult where session='$session' and rol='$rol1' and exam='FOURTH TERM EXAM' "; $res4111=mysqli_query($conn,$sel4111); $row4111=mysqli_fetch_array($res4111,MYSQLI_BOTH); $row411=mysqli_fetch_array($res411,MYSQLI_BOTH); if($row411['mark1']=='A'){'0';}else{$row411['mark1'] ;} if($row411['mark2']=='A'){'0';}else{$row411['mark2'] ;} if($row411['mark3']=='A'){'0';}else{$row411['mark3'] ;} if($row411['mark4']=='A'){'0';}else{$row411['mark4'] ;} if($row411['mark5']=='A'){'0';}else{$row411['mark5'] ;} if($row411['mark10']=='A'){'0';}else{$row411['mark10'] ;} if($row411['mark6']=='A'){'0';}else{$row411['mark6'] ;} if($row411['mark8']=='A'){'0';}else{$row411['mark8'] ;} if($row411['mark9']=='A'){'0';}else{$row411['mark9'] ;} if($row211['mark11']=='A'){'0';}else{$row211['mark11'] ;} $marktotal411=(int)$row411['mark1']+(int)$row411['mark2']+(int)$row411['mark3']+(int)$row411['mark4']+(int)$row411['mark5']+(int)$row411['mark9']+(int)$row411['mark11']; $per411=$marktotal411/3.5; $per411=$per411; //ECHO $marktotals; ///// for fourth term $row211=mysqli_fetch_array($res211,MYSQLI_BOTH); if($row211['mark1']=='A'){'0';}else{$row211['mark1'] ;} if($row211['mark2']=='A'){'0';}else{$row211['mark2'] ;} if($row211['mark3']=='A'){'0';}else{$row211['mark3'] ;} if($row211['mark4']=='A'){'0';}else{$row211['mark4'] ;} if($row211['mark5']=='A'){'0';}else{$row211['mark5'] ;} if($row211['mark10']=='A'){'0';}else{$row211['mark10'] ;} if($row211['mark7']=='A'){'0';}else{$row211['mark7'] ;} if($row211['mark8']=='A'){'0';}else{$row211['mark8'] ;} if($row211['mark9']=='A'){'0';}else{$row211['mark9'] ;} if($row211['mark11']=='A'){'0';}else{$row211['mark11'] ;} $marktotal211=(int)$row211['mark1']+(int)$row211['mark2']+(int)$row211['mark3']+(int)$row211['mark4']+(int)$row211['mark5']+(int)$row211['mark9']+(int)$row211['mark11']; $per211=$marktotal211/0.7; $per211=$per211; //echo $marktotal211; $all=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp1=$marktotal+$marktotals+$marktotal211+$marktotal411; $allp=$allp1/7; //$allp=$allp1/16; ?> <center> <?php $rol1=$row1['rol']; $sel5="select *from registration where id='$rol1' order by id desc"; $res5=mysqli_query($conn,$sel5); $row5=mysqli_fetch_array($res5,MYSQLI_BOTH); ?> <table frame="border" height="10%" width="100%" id="example"> <tr> <td align="center" COLSPAN="5"><img src="../images/mhi mark123.png" style="width:100%" height="140px" width="100%"/></td> </tr> </table> <table border="1px" width="100%" cellspacing="0"> <tr align="center"> <td><h4>Class: <?php echo $row3['subject'];?></h4></td><td colspan="2"><h4>ANNUAL EXAM-<?php echo $row3['session'];?>(<?php echo $board;?>)</h4></td><td ><h4>Roll Number: <?php echo $row3['id'];?></h4></td> </tr> <tr align=""> <td>Name</td><td colspan="2"><p><?php echo $row3['name'];?></p></td><td rowspan="4"> <center><img src="../code/img/<?php echo $row3['picture'];?>" height="80px" width="100px"/></center></td> </tr> <tr align=""> <td>Father Name</td><td colspan="2"><p><?php echo $row3['fname'];?></p></td> </tr> <tr align=""> <td>Mother Name</td><td colspan="2"><p><?php echo $row3['mname'];?></p></td> </tr> <tr align=""> <td>Date Of Birth</td><td colspan="2"><p><?php echo $row3['dob'];?></p></td> </tr> <tr align="center"> <td colspan="5"><h3>MARKS</h3></td> </tr> <table cellspacing="0" border="1px" width="100%"> <tr align="center" style="font-weight:bold"> <td rowspan="2">SUBJECT</td><td colspan="2">FIRST TERM EXAM.</td><td colspan="2">SECOND TERM EXAM.</td><td colspan="2">THIRD TERM EXAM.</td><td colspan="2">ANNUAL EXAM.</td> </tr> <tr align="center"> <td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td><td style="font-weight:bold">Max. Marks</td><td style="font-weight:bold">Obtained Marks</td> </tr> <tr align="center"> <td style="text-align:left">HINDI</td><td>10</td><td><?php echo $row1['mark1'];?></td><td>30</td><td><?php echo $row31['mark1'];?></td><td>10</td><td STYLE=''><?php echo $row2111['mark1'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark1'];?></td> </tr> <tr align="center"> <td style="text-align:left">ENGLISH</td><td>10</td><td><?php echo $row1['mark2'];?></td><td>30</td><td><?php echo $row31['mark2'];?></td><td>10</td><td><?php echo $row2111['mark2'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark2'];?></td> </tr> <tr align="center"> <td style="text-align:left">MATHS</td><td>10</td><td><?php echo $row1['mark3'];?></td><td>30</td><td><?php echo $row31['mark3'];?></td><td>10</td><td><?php echo $row2111['mark3'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark3'];?></td> </tr> <tr align="center"> <td style="text-align:left">SCIENCE</td><td>10</td><td><?php echo $row1['mark4'];?></td><td>30</td><td><?php echo $row31['mark4'];?></td><td>10</td><td><?php echo $row2111['mark4'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark4'];?></td> </tr> <tr align="center"> <td style="text-align:left">ART</td><td>10</td><td><?php echo $row1['mark5'];?></td><td>30</td><td><?php echo $row31['mark5'];?></td><td>10</td><td><?php echo $row2111['mark5'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark5'];?></td> </tr> <tr align="center"> <td style="text-align:left">SANSKRIT</td><td>10</td><td><?php echo $row1['mark9'];?></td><td>30</td><td><?php echo $row31['mark9'];?></td><td>10</td><td><?php echo $row2111['mark9'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark9'];?></td> </tr> <tr align="center"> <td style="text-align:left">SOCI STU</td><td>10</td><td><?php echo $row1['mark11'];?></td><td>30</td><td><?php echo $row31['mark11'];?></td><td>10</td><td><?php echo $row2111['mark11'];?></td><td>50</td><td STYLE=''><?php echo $row4111['mark11'];?></td> </tr> <tr align="center"> <td style="text-align:left">HOME SCI/AGRI</td><td>Grade</td><td>A1</td><td>Grade</td><td>A1</td><td>Grade</td><td>A1</td><td>Grade</td><td STYLE=''>A1</td> </tr> <tr align="center"> <td style="text-align:left">URDU</td><td>GRADE</td><td>A1</td><td>GRADE</td><td>A1</td><td>GRADE</td><td>A1</td><td>GRADE</td><td STYLE=''>A1</td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotals;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal211;?></td><td style="font-weight:bold">TOTAL</td><td style="font-weight:bold"><?php echo $marktotal411;?></td> </tr> <tr align="center"> <td style="text-align:left"></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$pers",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per211",0,5).'%';?></td><td style="font-weight:bold">PER</td><td style="font-weight:bold;color:red"><?php echo substr("$per411",0,5).'%';?></td> </tr> <tr> <td colspan="4" align="center"><h4><br/>ALL TOTAL RESULT<br/><br/>ALL TOTAL PER<br/><br/>DIVISION</h4><br/></td><td colspan="6" align="center"><h4 style="color:red"><?php echo $all.'/700';?><BR/><br/><?php echo substr("$allp",0,5).'%';?> <BR/><BR/><?PHP if($allp>=33 ) { if($allp>=33 and $allp<=45) { echo "THIRD"; } else if($allp>45 and $allp<60) { echo "SECOND"; } else if($allp=60 and $allp<=100) { echo "FIRST"; } } ELSE { echo "NO OBTAIN"; } ?> </h4></td> </tr> <tr> <td colspan="4" align="center"><h4>Guardian's Signature</h4><br/><br/><br/></td><td colspan="5" align="center"><h4>Principal's Signature</h4><br/><br/><br/></td> </tr> <tr align="center"> <td>Note:</td><td colspan="8"><i>Please make Signature Principal and Guardian in Space.</i></td> </tr> </table> <center><img src="../images/mhi mark1.png" id="jk" style="position:relative;height:500px;width:100%;margin-top:-1800px;z-index:-1;"/></center> <?php ?> </body> </html> <?php }?>