git://git.onelab.eu
/
plcapi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
5165658
)
Remove legacy code from vardemo demo file
author
gggeek
<giunta.gaetano@gmail.com>
Fri, 17 Apr 2015 23:34:23 +0000
(
00:34
+0100)
committer
gggeek
<giunta.gaetano@gmail.com>
Fri, 17 Apr 2015 23:34:23 +0000
(
00:34
+0100)
demo/vardemo.php
patch
|
blob
|
history
diff --git
a/demo/vardemo.php
b/demo/vardemo.php
index
4f91deb
..
d24d04e
100644
(file)
--- a/
demo/vardemo.php
+++ b/
demo/vardemo.php
@@
-2,11
+2,10
@@
<head><title>xmlrpc</title></head>
<body>
<?php
<head><title>xmlrpc</title></head>
<body>
<?php
-include_once __DIR__ . "/../vendor/autoload.php";
-include_once __DIR__ . "/../
lib/xmlrpc.inc
";
+include_once __DIR__ . "/../
vendor/autoload.php
";
-$
f
= new PhpXmlRpc\Request('examples.getStateName');
+$
req
= new PhpXmlRpc\Request('examples.getStateName');
print "<h3>Testing value serialization</h3>\n";
print "<h3>Testing value serialization</h3>\n";
@@
-69,25
+68,26
@@
And turned it into nylon", "base64"
print "<PRE>" . htmlentities($w->serialize()) . "</PRE>";
print "<PRE>Value of base64 string is: '" . $w->scalarval() . "'</PRE>";
print "<PRE>" . htmlentities($w->serialize()) . "</PRE>";
print "<PRE>Value of base64 string is: '" . $w->scalarval() . "'</PRE>";
-$
f
->method('');
-$
f
->addParam(new PhpXmlRpc\Value("41", "int"));
+$
req
->method('');
+$
req
->addParam(new PhpXmlRpc\Value("41", "int"));
print "<h3>Testing request serialization</h3>\n";
print "<h3>Testing request serialization</h3>\n";
-$op = $
f
->serialize();
+$op = $
req
->serialize();
print "<PRE>" . htmlentities($op) . "</PRE>";
print "<h3>Testing ISO date format</h3><pre>\n";
$t = time();
print "<PRE>" . htmlentities($op) . "</PRE>";
print "<h3>Testing ISO date format</h3><pre>\n";
$t = time();
-$date = iso8601_encode($t);
+$date =
PhpXmlRpc\Helper\Date::
iso8601_encode($t);
print "Now is $t --> $date\n";
print "Now is $t --> $date\n";
-print "Or in UTC, that is " . iso8601_encode($t, 1) . "\n";
-$tb = iso8601_decode($date);
+print "Or in UTC, that is " .
PhpXmlRpc\Helper\Date::
iso8601_encode($t, 1) . "\n";
+$tb =
PhpXmlRpc\Helper\Date::
iso8601_decode($date);
print "That is to say $date --> $tb\n";
print "That is to say $date --> $tb\n";
-print "Which comes out at " . iso8601_encode($tb) . "\n";
-print "Which was the time in UTC at " . iso8601_decode($date, 1) . "\n";
+print "Which comes out at " .
PhpXmlRpc\Helper\Date::
iso8601_encode($tb) . "\n";
+print "Which was the time in UTC at " .
PhpXmlRpc\Helper\Date::
iso8601_decode($date, 1) . "\n";
print "</pre>\n";
print "</pre>\n";
+
?>
</body>
</html>
?>
</body>
</html>