-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathabc.html
More file actions
52 lines (43 loc) · 1.53 KB
/
abc.html
File metadata and controls
52 lines (43 loc) · 1.53 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
<!doctype html>
<html>
<meta charset="utf-8">
<head>
</head>
<body>
<div align="left">
<h1>Student Portal</h1>
<form onsubmit="native()">
<input type="text" name="username" id="username" placeholder=" UserName"><br><br>
<input type="text" name="password" id="password" placeholder=" password"><br><br>
<input type="submit" value="login" target ="abc2.html"><br>
</form>
</div>
<!-- <button onclick="native()">click</button> -->
<script>
// called when the runtime is ready
// var Module = {
// onRuntimeInitialized: function () {
// alert('onRuntimeInitialized');
// }
// };
// // called from main()
// function onLoaded() {
// alert('Module is loaded');
// }
function native() {
// var abc = document.getElementById('para');
var a = document.getElementById('username').value;
var b = document.getElementById('password').value;
var uname = Module.ccall('world', 'string', ['string'], [a] , ['string'], [b]);
// var pwd = Module.ccall('world', 'string', );
// alert("welcome "+uname+"");
if (uname == "true") {
window.open("abc.html");
}
else
alert ("Login Failed..!");
}
</script>
<script async type="text/javascript" src="abc2.js"></script>
</body>
</html>