-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
51 lines (41 loc) · 1.08 KB
/
index.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
<!DOCTYPE html>
<html>
<head>
<title>JavaScript Utility Test Page</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
<script src="js/utility.js"></script>
</head>
<body>
<!-- This div will use to print Utility Results
This is only for test purposes
-->
<div id="printRes">
</div>
<div id="printIPvs">
</div>
<button onclick="multiLineWorker()">Multi-Line Alert Message</button>
<script>
function multiLineWorker() {
//MultiLine alert check
var myarr = ['Indu Prakash', 'An Indian Programmer.', '', 'Thank you!'];
//From Utility Method
multiLineAlert(myarr);
}
</script>
<script>
//Vailidate IP address with regular expression
var _flag=validateIPaddress("1.2.3.4");
//If flag true Valid IP otherwise In-valid IP.
if(_flag){
$("#printIPvs").html("Valid IP address");
}else{
$("#printIPvs").html("In-valid IP address");
}
</script>
<script>
//jquery Selector by ID
var str="Hello World";
$("#printRes").html(str);
</script>
</body>
</html>