Re: [Zotonic-Usr] Stream events to the browser

48 views
Skip to first unread message

Andreas Stenius

unread,
Jul 13, 2012, 7:57:58 AM7/13/12
to zotoni...@googlegroups.com

Have a look at mod_signal.

Sorry for the very terse reply; I'm on vacation, away from my computer...

//Andreas

Den 11 jul 2012 21:03 skrev "Behrad Zari" <beh...@gmail.com>:
Howdy,
I've a simple module which calls z_notifier:notify to broadcast events to clients.
Now I'm trying to write a simple comet page in which an elements gets updated 
by events published by the above module. I don't know how should I get notified
in my template and wire received events to a DOM element when using {%stream%}

Behrad Zari

unread,
Jul 14, 2012, 2:40:50 PM7/14/12
to zotoni...@googlegroups.com
Andreas,
I took a look at mod_signal,but there was no sample tpl that shows how should I bind my signals to javascript code?
Would you provide me a sample code that uses mod_signal to trigger an event in JS code? 
I'm digging more into mod_signal module but I'new not a native Erlanger!

Thanks,


On Friday, July 13, 2012 4:27:58 PM UTC+4:30, Andreas Stenius wrote:

Have a look at mod_signal.

Sorry for the very terse reply; I'm on vacation, away from my computer...

//Andreas

Den 11 jul 2012 21:03 skrev "Behrad Zari" 
Howdy,

Andreas Stenius

unread,
Jul 15, 2012, 10:27:11 AM7/15/12
to zotoni...@googlegroups.com

Search this list's archive, or look at the code for trackz ( http://github.com/kaos/trackz ) I use signals to update parts of the UI.

Reply all
Reply to author
Forward
0 new messages