[phpxmlrpc] a comparison of xmlrpc.*.inc and php4/ext/xmlrpc

2001-11-20 Thread Jim Barcelona

Dear List,

Currently at work we're trying to decide between xmlrpc*.inc files and
the new php4/ext/xmlrpc.

What do you folks think of the xmlrpc extension in php4? Have you tried
it out? Is it better to just use an include file than an extension in
terms of speed and memory use?

I've been very happy with the .inc files. :-)

Regards,
Jim

--

Jim Barcelona mailto:[EMAIL PROTECTED]
+39 3484 22 56 77 -- better living through php




--
For information about how to subscribe and unsubscribe from this list
visit http://xmlrpc.usefulinc.com/list.html



[phpxmlrpc] Re: XMLRPC stuff in PHP-PEAR

2001-11-20 Thread Edd Dumbill

Wolfram,

Some of the bugs you mention are fixed in the latest release of XML-RPC
for PHP.  The PEAR maintainers tell me that they're no longer going to
update the PEAR version as a C module for XML-RPC has been submitted, so
I think you'll have to work with the version now available at
http://phpxmlrpc.sourceforge.net/

I'm copying this reply to the project mailing list so anything that
affects the non-PEAR distro is recorded.

thanks

-- Edd

On Wed, 2001-11-21 at 00:33, Wolfram Kriesing wrote:
 Hello,
 
 i saw in the PEAR-XML_RPC that you are the original author of those 
 classes, since in PEAR people say that they are not going to change 
 anything in those classes, since they dont maintain them i thought i 
 might let you know what i have found and maybe you can tell me if 
 those are real bugs or if i was doing something wrong 
 and if those suggestions i made are realizable and if they make sense
 
 thanks
 
 wolfram
 
 --  Forwarded Message  --
 
 Subject: XMLRPC stuff
 Date: Wed, 31 Oct 2001 23:05:07 +0100
 From: Wolfram Kriesing [EMAIL PROTECTED]
 To: list [EMAIL PROTECTED]
 
 inspired by Stig's post, about the pear sub command communicating via
 xmlrpc
 (http://marc.theaimsgroup.com/?l=pear-devm=100430557325059w=2)
 i started fooling around with it too,
 when i saw there is the same API already converted to PEAR i just
 switched right to this
 
 and I found out the following
 
 1.
 i think it would be nice if the XML_RPC_Response::getval() would
 do a settype before returning the value, so the value is of the right
 type, so you can also do those (nasty but sometimes necessary) checks
 using ===
 i came across that when checking a boolean for ===true, it was ==true
 but the value was still an integer that's why === didnt work
 what are the opinions?
 
 2.
 XML_RPC_Server::verifySignature
 error return doesnt work properly, sorry but i havent found out why,
 yet
 Wanted ${wanted}, got ${got} at param ${pno})
 always returns
 Wanted , got  at param )
 
 
 examples
 ---
 on how to use XML_RPC can be found at
 http://wolfram.kriesing.de/pear/examples/XML_RPC/
 try xmlrpx.php  if you get Hi AuthxLogin than it worked :-)
 much to see ha? but it gets it via XMLRPC
 
 bugs
 -
 
 in XML_RPC/Server.php (i guess the require is no bug, just my fault,
 right?)
 
 --- Server.phpWed Oct 31 22:54:01 2001
 +++ myServer.php  Wed Oct 31 12:46:11 2001
 @@ -23,7 +23,7 @@
  // XML RPC Server class
  // requires: xmlrpc.inc
 
 -require_once XML/RPC.php;
 +require_once XML_RPC/RPC.php;
 
  // listMethods: either a string, or nothing
  $GLOBALS['XML_RPC_Server_listMethods_sig']=
 @@ -300,7 +300,7 @@
   // a debugging routine: just echos back the input
   // packet as a string value
 
 - $r=new XML_RPC_Response;
 + $r=new XML_RPC_Response(0);
   $r-xv=new XML_RPC_Value( 'Aha said I: ' . $HTTP_RAW_POST_DATA,
 string);
   print $r-serialize();
}
 
 
 the first bug was the reason why my booleans were not returned
 properly, the XML-response was correct, but the translation to a php
 value didnt work, it was always 0, it works with this fix, but i dont
 know if that is really the right place to fix the bug
 
 the second
 i guess it was meant to return the PEAR_Error ... right?
 
 --- RPC.php   Wed Oct 31 22:53:59 2001
 +++ myRPC.php Wed Oct 31 21:52:19 2001
 @@ -229,6 +229,7 @@
  $XML_RPC_xh[$parser]['ac']=true;
  else
  $XML_RPC_xh[$parser]['ac']=false;
 +$XML_RPC_xh[$parser]['st'].=$XML_RPC_xh[$parser]['ac'];
 
  $XML_RPC_xh[$parser]['vt']=strtolower($name);
  // Drop through intentionally.
 @@ -471,10 +472,10 @@
  }
 
  if(!$fp  $this-proxy) {
 -PEAR::raiseError(Connection to proxy server
  .$this-proxy.:.$this-proxy_port. failed);
 +return PEAR::raiseError(Connection to proxy server
  .$this-proxy.:.$this-proxy_port. failed);
  }
  else if(!$fp) {
 -PEAR::raiseError(Connection to RPC server
 .$this-server.
  failed);
 +return PEAR::raiseError(Connection to RPC server
 .$this-server.
  failed);
  }
 
 
 
 --
 Wolfram



msg00050/pgp0.pgp
Description: PGP signature