D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
diafrica
/
result.dominicaninstitute.org
/
Filename :
listtranscripts.php
back
Copy
<?php if (!$_SESSION){ session_start(); } $acc=$_SESSION['acc']; $yto=$_SESSION['yto']; $start=''; $loop=''; $finish=''; if(isset($acc) && ($acc=="administratoroftheduresult2018byto")){?> <?php include("Connecter/dataconn.php"); ?> <?php if (isset($_GET['arhtab'])) { unset($temp); if(isset($_GET['arhtab'])){ $_GET['arhtab']=trim($_GET['arhtab']); if(preg_match('/^[0-9]/u',$_GET['arhtab'])){ settype($_GET['arhtab'], 'int'); $temp=(int)$_GET['arhtab']; } } if(!isset($temp)){echo "Sorry! Wrong Data!"; exit();} $deltab=$temp; $sql=sprintf("update transcripts set archived='Yes' where sn = %s", mysql_real_escape_string($deltab)); $result=mysql_query($sql,$csn) or die(mysql_error()); } if (isset($_GET['unarhtab'])) { unset($temp); if(isset($_GET['unarhtab'])){ $_GET['unarhtab']=trim($_GET['unarhtab']); if(preg_match('/^[0-9]/u',$_GET['unarhtab'])){ settype($_GET['unarhtab'], 'int'); $temp=(int)$_GET['unarhtab']; } } if(!isset($temp)){echo "Sorry! Wrong Data!"; exit();} $deltab=$temp; $sql=sprintf("update transcripts set archived='No' where sn = %s", mysql_real_escape_string($deltab)); $result=mysql_query($sql,$csn) or die(mysql_error()); } $query_dio1 = "SELECT * FROM transcripts where archived='No' order by dater desc"; $dio1 = mysql_query($query_dio1, $csn) or die(mysql_error()); $row_dio1 = mysql_fetch_array($dio1); $totalRows_dio1 = mysql_num_rows($dio1); $num = mysql_num_rows($dio1); $query_dio = "SELECT * FROM transcripts where archived='Yes' order by dater desc"; $dio = mysql_query($query_dio, $csn) or die(mysql_error()); $row_dio = mysql_fetch_array($dio); $totalRows_dio = mysql_num_rows($dio); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <?php include("head.php"); ?> </head> <body> <?php include("top.php"); ?> <?php include("dtable0.php"); ?> <?php include("nav.php"); ?> <?php include("dtable1.php"); ?> <?php include("topcontainer.php"); ?> <!--Content Goes Here--> <div class="headingbiggest">Transcript Requests…</div> <hr /> <p> </p> <div class="headingbigger"><b>Pending Transcript Requests</b></div><hr /> <?php if ($totalRows_dio1>0) { ?> <?php $loop=25; if (!isset($_GET['start'])){ $start=1; $finish=($start + $loop)-1; if ($finish > $num){ $finish=$num; } $i = ($start - 1); } else { $start=$_GET['start']; $finish=($start + $loop)-1; if ($finish > $num){ $finish=$num; } $i = ($start - 1); } ?> <table width="98%"> <?php while($i < $finish){ $matric=mysql_result($dio1,$i,"matric"); $institute=mysql_result($dio1,$i,"institute"); $address=mysql_result($dio1,$i,"address"); $dater=mysql_result($dio1,$i,"dater"); $id=mysql_result($dio1,$i,"sn"); ?> <tr valign="top"> <td style="border-bottom:1px solid #333333;"> <?php $zz = $matric; $sql="select * from students where sn=$zz"; $result=mysql_query($sql); $row=mysql_fetch_array($result); echo(strtoupper($row['surname']).", ".$row['firstname']." ".$row['othernames']." [".$row['matric']."]"); ?> </td><td> </td> <td style="border-bottom:1px solid #333333;"><?php echo $institute; ?><br /><?php echo $address; ?></td><td> </td> <td style="border-bottom:1px solid #333333;"> <a href="listtranscripts.php?arhtab=<?php echo $id; ?>">Mark as Completed</a> </td></tr> <?php $i++; } ?> </table> <?php } else { echo ("None Found!"); } ?> <table width="80%" border="0" align="center" class="linktable" style="background-color:#ccc;"> <tr> <td> <?php if($start==1){ echo("First"); } else { echo("<a href='" . $_SERVER['PHP_SELF'] . "?start=1'>First</a>"); } ?> </td> <td> <?php if($start==1){ echo("Previous"); } else { $cc=$start-$loop; echo("<a href='" . $_SERVER['PHP_SELF'] . "?start=$cc'>Previous</a>"); } ?> </td> <td><?php echo("Showing Record(s) $start to $finish of $num record(s)");?></td> <td> <?php if($finish==$num){ echo("Next"); } else { $cc=$finish+1; echo("<a href='" . $_SERVER['PHP_SELF'] . "?start=$cc'>Next</a>"); } ?> </td> <td> <?php if($finish==$num){ echo("Last"); } else { $cc=(($num-($num % $loop))+1); echo("<a href='" . $_SERVER['PHP_SELF'] . "?start=$cc'>Last</a>"); } ?> </td> </tr></table> <p> </p><p> </p> <div class="headingbigger"><b>Completed Transcript Requests</b></div><hr /> <?php if ($totalRows_dio>0) { ?> <table width="98%"> <?php do { ?><tr valign="top"> <td style="border-bottom:1px solid #333333;"> <?php $zz = $row_dio['matric']; $sql="select * from students where sn=$zz"; $result=mysql_query($sql); $row=mysql_fetch_array($result); echo(strtoupper($row['surname']).", ".$row['firstname']." ".$row['othernames']." [".$row['matric']."]"); ?> </td><td> </td> <td style="border-bottom:1px solid #333333;"><?php echo $row_dio['institute']; ?></td><td> </td> <td style="border-bottom:1px solid #333333;"> <a href="listtranscripts.php?unarhtab=<?php echo $row_dio['sn']; ?>">Mark as UnCompleted</a> </td> </tr> <?php } while ($row_dio = mysql_fetch_array($dio)); ?> </table> <?php } else { echo ("None Found!"); } ?> <p> </p> <p><hr /><a href="dadmin.php">Back to Home Page</a></p> <p> </p> <!--Content Ends Here--> <?php include("bottomcontainer.php"); ?> <?php include("dtable2.php"); ?> <?php include("side.php"); ?> <?php include("dtable3.php"); ?> <?php include("foot.php"); ?> </body> </html> <?php } else { include("ddadmin.php"); }?>