forked from DhananjayPurohit/ISO-12-E1
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathquestion.html
executable file
·177 lines (169 loc) · 6.72 KB
/
question.html
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
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title>Feedback Form</title>
<script
src="https://code.jquery.com/jquery-2.2.4.min.js"
integrity="sha256-BbhdlvQf/xTY9gja0Dq3HiwQF8LaCRTXxZKRutelT44="
crossorigin="anonymous"></script>
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<!-- Compiled and minified CSS -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css">
<link href="https://fonts.googleapis.com/css?family=Raleway|Roboto&display=swap" rel="stylesheet">
<!-- Compiled and minified JavaScript -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/js/materialize.min.js"></script>
<style media="screen">
p{
font-size:larger;
}
</style>
</head>
<body>
<nav class="nav-extended" style="background-color:#D7726A;opacity:0.9">
<div class="nav-wrapper" style="height:100px;">
<a href="#" class="brand-logo" style="margin:20px;font-size:50px;font-family:Roboto">Feedback Form</a>
<a href="#" data-target="mobile-demo" class="sidenav-trigger"><i class="material-icons">menu</i></a>
</div>
</nav>
<div class="" style="background-color:#275660">
<img src='homeimage1.jpeg' height="300px" style="margin-left:0px;width:450px;">
</div>
<div class="row">
<div class="col s12 m3"></div>
<div class="col s12 m6" style="margin-top:-100px">
<center>
<div class="card horizontal " style="width:60%">
<div class="card-stacked">
<div class="card-content">
<!-- <p>Select Teacher</p> -->
</div>
<div class="card-action">
<select>
<option value="" disabled selected>Select Teacher</option>
<option value="5">Jon Doe</option>
<option value="4">Harry San</option>
<option value="3">Vedang Joshi</option>
<option value="2">Peter Bell</option>
<option value="1">Raj Jain</option>
</select>
</div>
</div>
</div>
</center>
<br/><br/>
<div class="card horizontal">
<div class="card-stacked">
<div class="card-content">
<p>Does the teacher take classes regularly?</p>
</div>
<div class="card-action">
<select id="q1">
<option value="" disabled selected>Choose your option</option>
<option value="5">Excellent</option>
<option value="4">Good</option>
<option value="3">Fair</option>
<option value="2">Poor</option>
<option value="1">Very Poor</option>
</select>
</div>
</div>
</div>
<div class="card horizontal">
<div class="card-stacked">
<div class="card-content">
<p>Is the teacher friendly while explaining doubts?</p>
</div>
<div class="card-action">
<select id="q2">
<option value="" disabled selected>Choose your option</option>
<option value="5">Excellent</option>
<option value="4">Good</option>
<option value="3">Fair</option>
<option value="2">Poor</option>
<option value="1">Very Poor</option>
</select>
</div>
</div>
</div>
<div class="card horizontal">
<div class="card-stacked">
<div class="card-content">
<p>The teacher maintains enthusiasm as well as discipline in the class?</p>
</div>
<div class="card-action">
<select id="q3">
<option value="" disabled selected>Choose your option</option>
<option value="5">Excellent</option>
<option value="4">Good</option>
<option value="3">Fair</option>
<option value="2">Poor</option>
<option value="1">Very Poor</option>
</select>
</div>
</div>
</div>
<div class="card horizontal">
<div class="card-stacked">
<div class="card-content">
<p>Does the teacher use technology and practical examples to explain tough concepts?</p>
</div>
<div class="card-action">
<select id="q4">
<option value="" disabled selected>Choose your option</option>
<option value="5">Excellent</option>
<option value="4">Good</option>
<option value="3">Fair</option>
<option value="2">Poor</option>
<option value="1">Very Poor</option>
</select>
</div>
</div>
</div>
<div class="card horizontal">
<div class="card-stacked">
<div class="card-content">
<p>Your opinion?</p>
</div>
<div class="card-action">
<div class="input-field col s12">
<textarea id="op" class="materialize-textarea"></textarea>
<label for="textarea1">Comments</label>
</div>
</div>
</div>
</div>
<center>
<button class="btn waves-effect waves-light" type="submit" name="action">Submit
<i class="material-icons right">send</i>
</button>
</center>
</div>
<div class="col s12 m4">
</div>
</div>
<script>
$(document).ready(function(){
$('select').formSelect();
});
var myHeaders = new Headers();
var formdata = new FormData();
formdata.append("ques_1", document.getElementById("q1").value);
formdata.append("ques_2", document.getElementById("q2").value);
formdata.append("ques_3", document.getElementById("q3").value);
formdata.append("ques_4", document.getElementById("q4").value);
formdata.append("teacher", "VJ");
formdata.append("opinion", document.getElementById("op").val());
var requestOptions = {
method: 'POST',
headers: myHeaders,
body: formdata,
redirect: 'follow'
};
fetch("http://127.0.0.1:5000/post_feedback", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));
</script>
</body>
</html>