HEX
Server: Apache
System: Linux sg2plmcpnl492417.prod.sin2.secureserver.net 4.18.0-553.58.1.lve.el8.x86_64 #1 SMP Fri Jul 4 12:07:06 UTC 2025 x86_64
User: nyiet8349bzl (9207396)
PHP: 8.1.34
Disabled: NONE
Upload Files
File: /home/nyiet8349bzl/Backup/sbc_back/homedir/public_html/e-data.php
<?php
include("config/connection.php");
$connection = new createCon();
$connection->connect();
$dep = $_GET['Dep'];
$tea = $_GET['Teacher'];
?>
<!DOCTYPE html>
<html lang="en">
	<head>
		<title>Shaheed Bhagat Singh College</title>
		<!-- META TAGS -->
		<meta charset="utf-8">
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<meta name="viewport" content="width=device-width, initial-scale=1">
		<meta name="description" content="#">
		<meta name="keyword" content="#">
		<?php include 'inc/header.php';?>
	</head>
	<body>
		</br>
		
			<div class="container">
				<div class="row">
					<div class="col-md-12">
					
						<div class="big_cont_sec">
							<div class="list-group">
								<a href="javascript:void(0)" class="list-group-item active">E-Data</a>
								<?php 
									$sql = mysqli_query($connection->myconn, "SELECT * FROM work WHERE subject_id = '".$dep."' AND teacher_id = '".$tea."' AND action='1' ORDER BY created_on DESC");
									while($rows = mysqli_fetch_array($sql))
									{
									    $filename = $rows['image'];
										$ext = explode('.', $filename);
										$allExtarray = array("pdf","docx","doc","png","jpg","jpeg","pptx","ppt");
										if(!in_array($ext[1],$allExtarray))
										{
								?>
								        <a class="list-group-item" href="<?php echo $rows['image'];?>" target="new"><i class="fa fa-book" aria-hidden="true"></i> <?php echo $rows[name];?> <span class="pull-right"><?php echo date('d-M-Y',strtotime($rows['created_on']));?></span></a>
								<?php
										} else {
								?>
								        <a class="list-group-item" href="pdf/resources/<?php echo $rows['image'];?>" target="new"><i class="fa fa-book" aria-hidden="true"></i> <?php echo $rows[name];?> <span class="pull-right"><?php echo date('d-M-Y',strtotime($rows['created_on']));?></a>
								<?php
									} }
								?>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
		<?php include 'inc/footer.php';?>
	</body>
</html>