-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path5.html
More file actions
73 lines (68 loc) · 2.85 KB
/
5.html
File metadata and controls
73 lines (68 loc) · 2.85 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
<html>
<head>
<title>
5th Page...
</title>
</head>
<style type="text/css">
body
{
background:#78c4c7;
background-size: cover;
background-attachment: fixed;
text-align:center;
}
</style>
<body>
<form name=str4 action="">
<h1><u>Finding a unicode of a character(charCodeAt function) </u></h1>
<br>
<input type="label" id="l1" value="Enter Your String"> =<input type="text" id="box1"><br>
<br>
<b>Enter index no. of character to find out its unicode: </b> =<input type="text" id="box2"><br>
<br>
<input type="button" id="Create3" value="Print" onclick="uni()"> <input type="Reset" id="re5" value="Reset" onclick="document.forms.str4.reset()/">
<br>
<br>
<b><u>Unicode of entered index character is:</u></b> <input type="text" id="box3"><br>
<br>
<br>
<b><hr></b>
<h1><u>Dividing Text(Split function) </u></h1>
<br>
<b>Enter your string</b> =<input type="text" id="box4"><br>
<br>
<b>Enter character from which string divides</b> =<input type="text" id="box5"><br>
<br>
<input type="button" id="Create4" value="Divide" onclick="divide()"> <input type="Reset" id="re6" value="Reset" onclick="document.forms.str4.reset()/">
<br>
<br>
<b>Divided strings are:</b> <input type="text" id="box6">
<br>
<br>
<b><hr></b>
<b><hr></b>
<input type="button" id="btnpre2" value="Previous Page" onclick="previous()">
</form>
<script>
function uni()
{
var txt=document.getElementById("box1").value
var a=document.getElementById("box2").value
var b=txt.charCodeAt(a);
document.getElementById("box3").value=b
}
function divide()
{
var c=document.getElementById("box4").value
var d=document.getElementById("box5").value
var e=c.split(d);
document.getElementById("box6").value=e
}
function previous()
{
document.location.href="4.html";
}
</script>
</body>
</html>