set server and port clientside?

125 views
Skip to first unread message

stefa_n

unread,
Oct 24, 2011, 3:35:25 AM10/24/11
to nowjs
Hi,
if now.js isn't hosted by the server running nowJS, is there a way to
use server and port stored locally?
Thanks.
Stefan

Eric Zhang

unread,
Oct 24, 2011, 4:18:32 AM10/24/11
to no...@googlegroups.com
Hey Stefan,


Yes!

Instead of using the version of the client lib hosted at
http://yourserver/nowjs/now.js,

Use the default client provided in GitHub:
https://github.com/Flotype/now/blob/master/lib/client/now.js

And on the client side, call the manual connection function:
`window.now = nowInitialize('http://myserver:9000');


Eric

--
Co-Founder @ Flotype, makers of NowJS

Brendan

unread,
Jan 11, 2012, 11:58:48 PM1/11/12
to no...@googlegroups.com
Note that this still seems to pull socket.io/socket.io.js from your server.
Reply all
Reply to author
Forward
0 new messages