Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Simple HTML WebSocket client for the ZeroMQ gateway
<title>ZWS Example</title>
<script type="text/javascript" src="" ></script>
<script language='javascript'>
$(document).ready(function() {
var ws = new WebSocket("ws://localhost:9999/test");
ws.onmessage = function(evt) {
$('#output').append('<br />');
ws.onopen = function(evt) {
ws.onerror = function(evt) {
ws.onclose = function(evt) {
<h1>ZMQ - WebSocket Example</h1>
<div id="conn_status">Not Connected</div>
<div id="output"></div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment