Skip to content

Instantly share code, notes, and snippets.

@elbruno
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save elbruno/d846949ea4345bacd1ff to your computer and use it in GitHub Desktop.
Save elbruno/d846949ea4345bacd1ff to your computer and use it in GitHub Desktop.
ElBruno - SignalR Html Client OnConnected On Hub II
<script type="text/javascript">
var hub;
$(window).ready(function () {
console.log("windows ready para SignalR");
hub = $.connection.SampleHub;
$.connection.hub.start().done(
function () {
var area = 'default';
console.log("hub started, area:" + area);
hub.server.JoinToArea(area);
});
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment