-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathquestions.php
executable file
·53 lines (43 loc) · 1.65 KB
/
questions.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<?php
session_start();
require 'config.php';
require 'admin_layout.php';
?>
<?php
/*
if(isset($_POST['Submit'])||isset($_SESSION['admin_name']))
{
$query = "select * from admin_login where username = \"".$_POST['admin_name']."\" and password = \"".$_POST['admin_pass']."\"";
if($result = mysqli_query($dbConn,$query))
{
$row = mysqli_fetch_array($result);
//printf("Welcome Admin!!!");
if(!isset($_SESSION['admin_name']))
{ $_SESSION['login']=true;
$_SESSION['admin_name']=$row[0];
}
*/ ?>
<div class="container-fluid" style="margin: 5%">
<div class="table-responsive">
<table class="table" border="0" align="center" style="width: 80%">
<col width="40%">
<col width="40%">
<col width="10%">
<col width="10%">
<thead class="thead-inverse" style="color: white"><tr><th>Problem</th><th>Problem Code</th></tr></thead>
<tbody>
<?php
$query2 = "select * from practice_problem";
$result2 = mysqli_query($dbConn,$query2);
while($row2 = mysqli_fetch_array($result2))
{
printf("<tr><td><a href=\"../portal/problem_definition.php?Name=".$row2[0]."\">".$row2[1]."</a></td><td><a href=\"terminal123.php?Code_id=".$row2[0]."\">".$row2[0]."</a></td><td> <a href=\"do_add.php?Name=".$row2[0]."\">Edit</a>
</td><td><a>Delete</a></td></tr>");
}
?>
</tbody>
</table>
</div>
</div>
</html>
</body