Skip to content

Instantly share code, notes, and snippets.

@danveloper
Created March 20, 2013 21:25
Show Gist options
  • Save danveloper/5208614 to your computer and use it in GitHub Desktop.
Save danveloper/5208614 to your computer and use it in GitHub Desktop.
UI Atmosphere Subscription (new logging instance) -- Real Time Logging Project
<!-- ... some rendered code, divs and shit, removed for brevity ... -->
<script>
(function() {
var url = '${createLink(uri: ApplicationHolder.application.config.grails.atmosphere.mappingUri)}/logchannel/${id}/${ip}/${hostname}';
$.atmosphere.subscribe(url, Logging.router, $.atmosphere.request = {transport:'websocket', fallbackTransport:'streaming'});
...
})();
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment