X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=debugger%2Faction.php;h=0d0a649eda2849dfed7bb893da0eca3bd076d032;hb=d8e180b0ca87bf675d5fda2099d49c9d0043cd42;hp=0345798e716b35e39864b8ea39a354fa5ff9116d;hpb=da824472c0045c183f40792b8c760c11d024005d;p=plcapi.git diff --git a/debugger/action.php b/debugger/action.php index 0345798..0d0a649 100644 --- a/debugger/action.php +++ b/debugger/action.php @@ -8,6 +8,9 @@ * @todo use ob_start to catch debug info and echo it AFTER method call results? * @todo be smarter in creating client stub for proxy/auth cases: only set appropriate property of client obj **/ + +header('Content-Type: text/html; charset=utf-8'); + ?> @@ -104,11 +107,11 @@ if ($action) { if (!class_exists('jsonrpc_client')) { die('Error: to debug the jsonrpc protocol the jsonrpc.inc file is needed'); } - $clientClass = 'PhpJsRpc\client'; - $requestClass = 'PhpJsRpc\request'; + $clientClass = 'PhpJsRpc\Client'; + $requestClass = 'PhpJsRpc\Request'; $protoName = 'JSONRPC'; } else { - $clientClass = 'PhpXmlRpc\client'; + $clientClass = 'PhpXmlRpc\Client'; $requestClass = 'PhpXmlRpc\Request'; $protoName = 'XMLRPC'; } @@ -239,7 +242,7 @@ if ($action) { // Before calling execute, echo out brief description of action taken + date and time ??? // this gives good user feedback for long-running methods... - echo '
Fault code: [" . htmlspecialchars($response->faultCode()) . - "] Reason: '" . htmlspecialchars($response->faultString()) . "'
\n"; + echo "Fault code: [" . htmlspecialchars($response->faultCode(), ENT_COMPAT, \PhpXmlRpc\PhpXmlRpc::$xmlrpc_internalencoding) . + "] Reason: '" . htmlspecialchars($response->faultString(), ENT_COMPAT, \PhpXmlRpc\PhpXmlRpc::$xmlrpc_internalencoding) . "'
\n"; echo(strftime("%d/%b/%Y:%H:%M:%S\n")); } else { // call succeeded: parse results - //echo 'Method | Description |
---|---|
Method ($max) | Description |
" . htmlspecialchars($rec->scalarval()) . " |