-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtest.html
More file actions
30 lines (28 loc) · 700 Bytes
/
Copy pathtest.html
File metadata and controls
30 lines (28 loc) · 700 Bytes
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
<!doctype html>
<html>
<head>
</head>
<body>
<div id="log"></div>
<script src="http://code.xrtml.org/xrtml-3.2.0.js"></script>
<script>
var appKey = 'YOUR_APP_KEY';
var authToken = 'abcdefg';
var url = 'http://ortc-developers.realtime.co/server/2.1';
xRTML.ready(function(){
xRTML.Config.debug = true;
xRTML.ConnectionManager.create({
appKey: appKey,
authToken: authToken,
url: url,
channels: [{name: 'motion:cam1'}]
}).bind({
message: function (e) {
var content = document.getElementById('log').innerHTML;
document.getElementById('log').innerHTML = content + '<br />' + new Date() + ' - ' + e.message;
}
});
});
</script>
</body>
</html>