-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
70 lines (63 loc) · 2.06 KB
/
index.html
File metadata and controls
70 lines (63 loc) · 2.06 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
<!DOCTYPE html>
<html class="ui-mobile" >
<head >
<meta charset="utf-8" >
<meta name="viewport" content="width=device-width, initial-scale=1" >
<link rel="stylesheet" href="lib/jquery.mobile-1.2.0.css" >
<link rel="stylesheet" href="main.css">
<script src="lib/jquery.js" ></script>
<script src="lib/jquery.mobile-1.2.0.js" ></script>
<script src="http://free.dangsam.com:8000/socket.io/socket.io.js"></script>
<script src="main.js" ></script>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-4906577-6']);
_gaq.push(['_setDomainName', 'dangsam.com']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
$(function() {
var socket = io.connect('http://free.dangsam.com:8000');
refreshServiceList();
socket.on('services', function(data) {
console.log(data);
services = data;
refreshServiceList();
});
});
var services = {};
function refreshServiceList() {
var list = $('#Listview1');
list.empty();
list.append($('<li/>', {'data-role': 'list-divider'}).text('Services'));
for (var id in services) {
var svc = services[id];
var item = $('<li/>')
.append($('<a/>', {href: svc.url, 'data-ajax': false})
.append($('<h1/>').text(svc.name))
.append($('<span/>', {'class': 'ui-li-count'}).text(svc.count))
.append($('<p/>').text(svc.desc)));
list.append(item);
}
list.listview('refresh');
}
</script>
<title>Free Chat</title>
</head>
<body>
<div data-role="page" id="page1">
<div data-role="header">
<h4 style="margin-left: 0%; margin-right: 0%">Free Service Zone</h4>
</div>
<div data-role="content" id="Content1">
<ul data-role="listview" id="Listview1" data-inset="true" class="">
<li data-role="list-divider">Services</li>
</ul>
<h4>Made in Korea</h2>
</div>
</div>
</body>
</html>