Call of now.runClientFunctionWithStringParameter(function(paramText){alert(paramText);}); works just fine - result is client alert window with text "passed by server".
But invocation of line now.runClientFunctionWithFunctionParameter(function(paramCallbackFunction){paramCallbackFunction();}); results on server with this error message:
9 Jul 18:57:08 - Your node instance does not have root privileges. This means that the flash XML policy file will be served inline instead of on port 843. This will slow down initial connections slightly.
9 Jul 18:57:08 - socket.io ready - accepting connections
9 Jul 18:57:23 - Initializing client with transport "websocket"
9 Jul 18:57:23 - Client 9094739998690784 connected
runClientFunctionWithFunctionParameter()::1
runClientFunctionWithFunctionParameter()::2
{ stack: [Getter/Setter],
arguments: [ 'closureTimeout' ],
type: 'not_defined',
message: [Getter/Setter] }
ReferenceError: closureTimeout is not defined
at /home/run/node_modules/now/lib/nowServerLib.js:212:11
at Object.<anonymous> (/home/run/Projekty/poligon/nodejs/issue_000.js:30:5)
at Object.<anonymous> (native)
at Object.remoteCall (/home/run/node_modules/now/lib/nowServerLib.js:90:19)
at [object Object].<anonymous> (/home/run/node_modules/now/lib/nowServerLib.js:288:46)
at [object Object].emit (events.js:64:17)
at [object Object]._onMessage (/home/run/node_modules/now/node_modules/socket.io/lib/socket.io/client.js:58:10)
at Parser.<anonymous> (native)
at Parser.emit (events.js:64:17)
at Parser.parse (/home/run/node_modules/now/node_modules/socket.io/lib/socket.io/transports/websocket.js:195:12)
hello,
this is my server code
and client code
Call of
now.runClientFunctionWithStringParameter(function(paramText){alert(paramText);});
works just fine - result is client alert window with text "passed by server".But invocation of line
now.runClientFunctionWithFunctionParameter(function(paramCallbackFunction){paramCallbackFunction();});
results on server with this error message: