Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 27 lines (27 sloc) 1.092 kb
c384cf4 Initial commit.
Justin authored
1 <!doctype html>
2 <html lang="en">
3 <head>
4 <meta charset="utf-8">
5 <title>
6 Quote Stream
7 </title>
8 <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.js"></script>
9 <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.18/jquery-ui.js"></script>
5817d53 Version 0.2.0, see CHANGELOG
Justin authored
10 <script type="text/javascript" src="http://localhost:4000/socket.io/socket.io.js"></script>
c384cf4 Initial commit.
Justin authored
11 </head>
12 <script type="text/javascript">
13 $(document).ready(function() {
5817d53 Version 0.2.0, see CHANGELOG
Justin authored
14 var socket = io.connect("http://localhost:4000");
c384cf4 Initial commit.
Justin authored
15 socket.on('quote', function(data) {
16 var data = $("<pre>" + data + "</pre><hr />");
17 $("#quotes").append(data);
18 $("html, body").animate({ scrollTop: $(document).height() }, 100);
19 $(data).show("slide", { direction: "up" }, 250);
20 $(data).effect("highlight", {}, 1500);
21 });
22 });
23 </script>
24 <body>
25 <div id="quotes"></div>
26 </body>
27 </html>
Something went wrong with that request. Please try again.