Last change
on this file since 1742 was 1284, checked in by Sam Habiel, 13 years ago |
Added Sign-On Project, Bed Board, Tutorial, and Roll-and-Scroll emulator
|
File size:
765 bytes
|
Line | |
---|
1 | <ewd:config isFirstPage="true" websockets="true" cachePage="false">
|
---|
2 | <html>
|
---|
3 | <head>
|
---|
4 | <title>Roll and Scroll Emulator</title>
|
---|
5 | <script type="text/javascript">
|
---|
6 | //must be defined before body is loaded.
|
---|
7 | EWD.sockets.serverMessageHandler = function (msg)
|
---|
8 | {
|
---|
9 | document.getElementById("message").innerHTML = "Sent from GT.M: " + msg.message;
|
---|
10 | };
|
---|
11 |
|
---|
12 | //can only work after body is loaded. Body loads socket.io.
|
---|
13 | function helloSockets() {
|
---|
14 | EWD.sockets.sendMessage({type: "testing", message: "This is my message for you to use"});
|
---|
15 | };
|
---|
16 |
|
---|
17 | //GT.M Test
|
---|
18 | function GTMTest() {
|
---|
19 | EWD.sockets.sendMessage({type: "M", message: "hello"});
|
---|
20 | };
|
---|
21 |
|
---|
22 | </script>
|
---|
23 | </head>
|
---|
24 | <body onload="helloSockets()">
|
---|
25 | <div id="message">
|
---|
26 | </div>
|
---|
27 | </body>
|
---|
28 | </html>
|
---|
Note:
See
TracBrowser
for help on using the repository browser.