File: hello.js

package info (click to toggle)
jabsorb 1.3-2
  • links: PTS, VCS
  • area: non-free
  • in suites: squeeze, wheezy
  • size: 2,832 kB
  • ctags: 1,483
  • sloc: java: 10,590; jsp: 420; xml: 372; makefile: 8
file content (17 lines) | stat: -rw-r--r-- 306 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
var jsonrpc;

function onLoad()
{
  jsonrpc = new JSONRpcClient("JSON-RPC");
}

function resultCallback(result, e)
{
  alert("The server replied: " + result);
}

function clickHello()
{
  var whoNode = document.getElementById("who");
  var result = jsonrpc.hello.sayHello(resultCallback, whoNode.value);
}