summaryrefslogtreecommitdiffstats
path: root/zarb-ml/mageia-dev/attachments/20110208/69d2df41
diff options
context:
space:
mode:
Diffstat (limited to 'zarb-ml/mageia-dev/attachments/20110208/69d2df41')
-rw-r--r--zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment-0001.bin44
-rw-r--r--zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment.bin44
2 files changed, 88 insertions, 0 deletions
diff --git a/zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment-0001.bin b/zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment-0001.bin
new file mode 100644
index 000000000..193390946
--- /dev/null
+++ b/zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment-0001.bin
@@ -0,0 +1,44 @@
+<?php
+
+require_once('xmlrpc.inc');
+
+# prepare the call parameters
+$server = "http://sophie2.aero.jussieu.fr/rpc";
+
+$method = "rpms.info";
+
+$pkgid = $_SERVER['argv'][1];
+# the Sophie pkgid of a package must be given at the command line
+# example : $ php sophieinfo.php 4727e94730113216e19d04592bbc4cec
+
+$parameters = new xmlrpcval("$pkgid") ;
+
+print_r($server);
+print_r("\n");
+print_r($method);
+print_r("\n");
+
+print_r($parameters);
+print_r("\n");
+
+$message = new xmlrpcmsg($method, array($parameters));
+
+# create the client, telling it which server to call
+$client = new xmlrpc_client($server);
+# (eventually) set options of the client
+$client->setDebug(2);
+
+# ask the client to send the message to the server
+$response = $client->send($message);
+
+# handle the response
+if (!$response->faultCode()) {
+ print "<HR>I got this value back<BR><PRE>" .
+ htmlentities($response->serialize()). "</PRE><HR>\n";
+} else {
+ print "Fault <BR>";
+ print "Code: " . htmlentities($response->faultCode()) . "<BR>" .
+ "Reason: '" . htmlentities($response->faultString()) . "'<BR>";
+}
+
+?> \ No newline at end of file
diff --git a/zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment.bin b/zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment.bin
new file mode 100644
index 000000000..193390946
--- /dev/null
+++ b/zarb-ml/mageia-dev/attachments/20110208/69d2df41/attachment.bin
@@ -0,0 +1,44 @@
+<?php
+
+require_once('xmlrpc.inc');
+
+# prepare the call parameters
+$server = "http://sophie2.aero.jussieu.fr/rpc";
+
+$method = "rpms.info";
+
+$pkgid = $_SERVER['argv'][1];
+# the Sophie pkgid of a package must be given at the command line
+# example : $ php sophieinfo.php 4727e94730113216e19d04592bbc4cec
+
+$parameters = new xmlrpcval("$pkgid") ;
+
+print_r($server);
+print_r("\n");
+print_r($method);
+print_r("\n");
+
+print_r($parameters);
+print_r("\n");
+
+$message = new xmlrpcmsg($method, array($parameters));
+
+# create the client, telling it which server to call
+$client = new xmlrpc_client($server);
+# (eventually) set options of the client
+$client->setDebug(2);
+
+# ask the client to send the message to the server
+$response = $client->send($message);
+
+# handle the response
+if (!$response->faultCode()) {
+ print "<HR>I got this value back<BR><PRE>" .
+ htmlentities($response->serialize()). "</PRE><HR>\n";
+} else {
+ print "Fault <BR>";
+ print "Code: " . htmlentities($response->faultCode()) . "<BR>" .
+ "Reason: '" . htmlentities($response->faultString()) . "'<BR>";
+}
+
+?> \ No newline at end of file