diff options
Diffstat (limited to 'web/poc_jsonrpc/nowplaying.html')
-rw-r--r-- | web/poc_jsonrpc/nowplaying.html | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/web/poc_jsonrpc/nowplaying.html b/web/poc_jsonrpc/nowplaying.html index d4298147de..c7f6149ac0 100644 --- a/web/poc_jsonrpc/nowplaying.html +++ b/web/poc_jsonrpc/nowplaying.html @@ -7,7 +7,7 @@ function CallMethod(method) { var http_request = new XMLHttpRequest(); - http_request.open( "POST", "jsonrpc", false ); + http_request.open( "POST", "/jsonrpc", false ); http_request.send('{"jsonrpc": "2.0", "method": "' + method + '", "params": { "fields": ["title", "plot"] }, "id": 1}'); window.location.reload( false ); } @@ -15,7 +15,7 @@ function CallMethod(method) function CallPlay(player, playlistItem) { var http_request = new XMLHttpRequest(); - http_request.open( "POST", "jsonrpc", false ); + http_request.open( "POST", "/jsonrpc", false ); http_request.send('{"jsonrpc": "2.0", "method": "' + player + 'Playlist.Play", "params": ' + playlistItem + ', "id": 1}'); } @@ -40,7 +40,7 @@ function refresh() <script type="text/javascript"> setTimeout( "refresh()", 5*1000 ); var http_request = new XMLHttpRequest(); -http_request.open( "POST", "jsonrpc", false ); +http_request.open( "POST", "/jsonrpc", false ); http_request.send('{"jsonrpc": "2.0", "method": "Player.GetActivePlayers", "id": 1}'); var players = JSON.parse(http_request.responseText)["result"]; @@ -50,7 +50,7 @@ if (players["video"] || players["audio"]) { player = "Audio"; http_request = new XMLHttpRequest(); - http_request.open( "POST", "jsonrpc", false ); + http_request.open( "POST", "/jsonrpc", false ); http_request.send('{"jsonrpc": "2.0", "method": "' + player + 'Playlist.GetItems", "params": { "fields": ["title", "plot"] }, "id": 1}'); var the_object = JSON.parse(http_request.responseText); |