-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
58 lines (56 loc) · 1.82 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
52
53
54
55
56
57
58
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Simple Test of Silverpeas JSXC</title>
<!-- JQuery -->
<script src="https://code.jquery.com/jquery-2.2.4.min.js"></script>
<script src="https://code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>
<!-- JSXC and its dependencies -->
<script src="jsxc/lib/jquery.slimscroll.js"></script>
<script src="jsxc/lib/jquery.fullscreen.js"></script>
<script src="jsxc/lib/jsxc.dep.min.js"></script>
<script src="jsxc/jsxc.min.js"></script>
<!-- SilverChat and its dependencies -->
<script src="build/js/silverchat.js"></script>
<!-- CSS -->
<link href="https://code.jquery.com/ui/1.11.4/themes/ui-lightness/jquery-ui.css" media="all" rel="stylesheet" type="text/css"/>
<link href="jsxc/css/jsxc.css" media="all" rel="stylesheet" type="text/css"/>
<link href="css/silverchat.css" media="all" rel="stylesheet" type="text/css"/>
</head>
<body>
<h1>A Simple Test of SilverChat</h1>
<form id="form">
<input type="text" id="username" value="toto">
<input type="password" id="password" value="azerty">
<input type="submit" id="login" value="Login">
<a href="#" id="logout">Logout</a>
</form>
<script type="application/javascript">
$(function() {
$('#logout').click(function(evt) {
evt.stopImmediatePropagation();
SilverChat.stop().then(function() {
var win = (window.top ? window.top:window);
win.location = win.location;
});
});
$('#form').submit(function() {
SilverChat.init({
path : '.',
id : $('#username').val(),
password : $('#password').val(),
ice : {
server: 'im.silverpeas.net:3478',
auth: true
},
language : 'fr',
debug: true,
avatar: '.'
}).start();
return false;
});
});
</script>
</body>
</html>