O'Reilly logo

Firefox Hacks by Nigel McFarlane

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Hack #66. Work with Mozilla XML-RPC Services

Want web service scripting, but don't need SOAP's complexity? Use XML-RPC.

XML-RPC is a way for you to run methods on a server from a remote client. All commands and responses are formatted as XML. It's similar to SOAP [Hack #65] , and both are intended to solve the same sorts of problems. However, XML-RPC is a much simpler protocol.

Tip

XML-RPC was developed by UserLand Software. The specification is at http://www.xmlrpc.com/spec.

There are two major differences between XML-RPC and SOAP. First, XML-RPC has only eight data types: int, boolean, string, double, dateTime.iso8601, base64, array, and struct, whereas SOAP has many more data types and more can be added via XML Schema. Second, XML-RPC has no standardized discovery mechanisms, such as SOAP's WSDL or UDDI.

You might find that XML-RPC's "limitations" make it easier to learn than SOAP. With fewer requirements, it's easier to make your code work, and there are fewer things that can go wrong.

XML-RPC is widely deployed on web services across the Internet. Most weblog publishing software, for example, includes support for at least one of the major external editor protocols: Blogger API, MetaWeblog API, or Movable Type (mt) API.

Locate XML-RPC in Firefox

Firefox supports XML-RPC in the chrome. Your extensions can use XML-RPC to pass commands and data back and forth between Firefox and any web service with a published XML-RPC specification.

Review security arrangements

XML-RPC used in the chrome ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required