-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathQuestionPaperList.php
More file actions
84 lines (82 loc) · 2.82 KB
/
QuestionPaperList.php
File metadata and controls
84 lines (82 loc) · 2.82 KB
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
<?php
include_once 'Header.php';
$sql = "SELECT cqp . * , ccm.name AS category_name, mc.fullname as course_name
FROM mdl_qpg_question_paper cqp
LEFT JOIN mdl_question_categories ccm ON ccm.id = cqp.category_id
LEFT JOIN mdl_course mc ON mc.id = cqp.course_id
ORDER BY cqp.id DESC";
$questionPapers = GetAll($sql);
?>
<script type="text/javascript">
questionPaperListInit();
</script>
<div class="qpgContent">
<div class="qpgQuestionPaperList">
<table style="border:1px solid #cccccc;width:600px;" cellspacing="0" align="center">
<tr style="background: #0099FF;">
<td>
S.No
</td>
<td>
Subject
</td>
<td>
Category
</td>
<td>
Term
</td>
<td>
Year
</td>
</tr>
<?php
foreach($questionPapers as $key => $questionPaper)
{
?>
<tr class="qpgQuestionPaperRow" id="<?php echo $questionPaper['id'] ?>">
<td>
<?php echo ($key + 1); ?>
</td>
<td>
<?php echo $questionPaper['course_name'] ?>
</td>
<td>
<?php echo $questionPaper['category_name'] ?>
</td>
<td>
<?php echo $questionPaper['term'] ?>
</td>
<td>
<?php echo $questionPaper['year'] ?>
</td>
</tr>
<?php
}
?>
</table>
</div>
<div class="qpgQuestionPaperContents">
<div id="qpgQuestionPaperContainer">
<br />
<table style="width:600px;border-collapse: collapse;" align="center" border="1" cellspacing="0" cellpadding="10">
<tr>
<td id="qpgQuestionPaperRules">
</td>
</tr>
<tr>
<td colspan="1" align="center">
<!--<input type="button" value="Edit" onclick="" disabled="" />-->
<input type="button" value="View Question Paper" onclick="loadPage('PrepareQuestions.php?questionPaperId=','1')" />
<input type="button" value="Cancel" onclick="cancelClicked()" />
<input type="button" value="Delete" onclick="deleteClicked()" />
</td>
</tr>
</table>
</div>
</div>
<div style="text-align: center;">
<br />
<input type="button" value="Add New Question Paper Rule" onclick="loadPage('AddQuestionPaperRule.php')" />
</div>
</div>