-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
224 lines (219 loc) · 11 KB
/
index.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
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
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
<?php
error_reporting(0);
require("assets/db/db.php");
if ($_POST['sellist1']) {
$org = $_POST['sellist1'];
}
if ($_POST['sellist2']) {
$stream = $_POST['sellist2'];
}
if ($_POST['sellist3']) {
$mode = $_POST['sellist3'];
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Angluar Assignment</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.9/angular.min.js"></script>
</head>
<body>
<div class="alert alert-dark text-center">
<h3>Exam Prepration Online</h3>
</div>
<div class="container" data-ng-app="angularAssignment" data-ng-controller="angularCtrl">
<div class="row">
<div class="col-sm-4">
<div class="row alert alert-dark">
<form method="post" action="" style="width: 100%">
<div class="col-sm-12 text-right">
<button type="submit">Apply Filters</button>
</div>
<div class="col-sm-12">
<div class="form-group">
<label for="org">Organisation:</label>
<select class="form-control" id="org" name="sellist1">
<option value="">Select</option>
<?php
$getallcompanies = mysqli_query($conn, "select infoorg from infodata");
if (($num = mysqli_num_rows($getallcompanies)) > 0) {
while ($fte = mysqli_fetch_array($getallcompanies)) {
if($fte[0] == $org){
?>
<option selected="selected" value="<?php echo $fte[0] ?>"><?php echo $fte[0] ?></option>
<?php
}else {
?>
<option value="<?php echo $fte[0] ?>"><?php echo $fte[0] ?></option>
<?php
}
}
}
?>
</select>
</div>
<div class="form-group">
<label for="stream">Engineering Stream:</label>
<select class="form-control" id="stream" name="sellist2">
<option value="">Select</option>
<?php
$getallstreams = mysqli_query($conn, "select stream from infodata");
if (($num1 = mysqli_num_rows($getallstreams)) > 0) {
while ($fte1 = mysqli_fetch_array($getallstreams)) {
if($fte1[0] == $stream){
?>
<option selected="selected" value="<?php echo $fte1[0] ?>"><?php echo $fte1[0] ?></option>
<?php
}else {
?>
<option value="<?php echo $fte1[0] ?>"><?php echo $fte1[0] ?></option>
<?php
}
}
}
?>
</select>
</div>
<div class="form-group">
<label for="mode">Application Mode:</label>
<select class="form-control" id="Mode" name="sellist3">
<option value="">Select</option>
<?php
$getallmode = mysqli_query($conn, "select mode from infodata");
if (($num2 = mysqli_num_rows($getallmode)) > 0) {
while ($fte2 = mysqli_fetch_array($getallmode)) {
if($fte2[0] == $mode){
?>
<option selected="selected" value="<?php echo $fte2[0] ?>"><?php echo $fte2[0] ?></option>
<?php
}else {
?>
<option value="<?php echo $fte2[0] ?>"><?php echo $fte2[0] ?></option>
<?php
}
}
}
?>
</select>
</div>
</div>
</form>
</div>
<div class="row alert alert-dark">
<div class="col-sm-12 text-right"><span style="color:blue; cursor: pointer; text-decoration: underline"
data-ng-click="clear()">Clear ALL</span>/<span
style="color:blue; cursor: pointer; text-decoration: underline" data-ng-click="selct()">Select ALL</span>
</div>
<div class="col-sm-12">
<div class="form-check">
<label class="form-check-label">
<input type="checkbox" class="form-check-input" data-ng-click="selection()"
value="Selection" data-ng-checked="checkedq">Selection Procedure
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input type="checkbox" class="form-check-input" data-ng-click="hr()" value="HR"
data-ng-checked="checkedq">HR Questions
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input type="checkbox" class="form-check-input" data-ng-click="technical()"
value="Technical" data-ng-checked="checkedq">Technical Interviews
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input type="checkbox" class="form-check-input" data-ng-click="analytical()"
value="Analytical" data-ng-checked="checkedq">Analytical Questions
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input type="checkbox" class="form-check-input" data-ng-click="suggestion()"
value="Suggestions" data-ng-checked="checkedq">Suggestions
</label>
</div>
</div>
</div>
</div>
<div class="col-sm-8" style="max-height: 500px; overflow-y: scroll">
<h3 class="text-center">Interview Experiences :: <?php echo $org ?></h3>
<br>
<?php
$query = "select * from infodata";
if ($org != '' || $mode != '' || $stream != '') {
$query .= " where";
}
if ($org != '') {
$query .= " infoorg='" . $org . "'";
}
if ($stream != '' && $org != '') {
$query .= " and stream='" . $stream . "'";
} elseif ($stream != '') {
$query .= " stream='" . $stream . "'";
}
if (($mode != '' && $org != '') || ($mode != '' && $stream != '')) {
$query .= " and mode='" . $mode . "'";
} elseif ($mode != '') {
$query .= " mode='" . $mode . "'";
}
$alldetils = mysqli_query($conn, $query);
if (($nos = mysqli_num_rows($alldetils)) > 0) {
while ($fetch = mysqli_fetch_array($alldetils)) {
?>
<div class="card">
<div class="card-body">
<div class="loc">
<strong>Job Location</strong>: <?php echo $fetch[1] ?><br/>
</div>
<div class="organi">
<strong>Organisation</strong>: <?php echo $fetch[2] ?><br/>
</div>
<div class="appmode">
<strong>Application Mode</strong>: <?php echo $fetch[3] ?><br/>
</div>
<div class="selpro" data-ng-show="selpro">
<strong>Selection Procedure</strong>: <?php echo $fetch[4] ?><br/>
</div>
<div class="techni" data-ng-show="techni">
<strong>Technical Interview</strong>: <?php echo $fetch[5] ?><br/>
</div>
<div class="analy" data-ng-show="analy">
<strong>Analytical Questions</strong>: <?php echo $fetch[6] ?><br/>
</div>
<div class="hrque" data-ng-show="hrque">
<strong>HR Questions</strong>: <?php echo $fetch[7] ?><br/>
</div>
<div class="sugg" data-ng-show="sugg">
<strong>Suggestions</strong>: <?php echo $fetch[8] ?><br/>
</div>
<div class="sharedby">
<strong>Shared By</strong>: <?php echo $fetch[9] ?><br/>
</div>
</div>
</div>
<?php
}
}else{
?>
<div class="card">
<div class="card-body">
No Match Found!
</div>
</div>
<?php
}
?>
</div>
</div>
<script src="assets/js/index.js"></script>
</body>
</html>