
- Learn XML-RPC
- XML-RPC - Home
- XML-RPC - Introduction
- XML-RPC - Data Model
- XML-RPC - Request
- XML-RPC - Response
- XML-RPC - Fault
- XML-RPC - Examples
- XML-RPC - Summary
- XML-RPC Resources
- XML-RPC - Quick Guide
- XML-RPC - Useful Resources
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
XML-RPC - Fault Format
XML-RPC faults are a type of responses. If there was a problem in processing a XML-RPC request, the methodResponse element will contain a fault element instead of a params element. The fault element, like the params element, has only a single value that indicates something went wrong. A fault response might look like:
<?xml version="1.0"?> <methodResponse> <fault> <value><string>No such method!</string></value> </fault> </methodResponse>
A fault will also have an error code. XML-RPC doesn't standardize error codes at all. You'll need to check the documentation for particular packages to see how they handle faults.
A fault response could also look like:
<?xml version="1.0"?> <methodResponse> <fault> <value> <struct> <member> <name>code</name> <value><int>26</int></value> </member> <member> <name>message</name> <value><string>No such method!</string></value> </member> </struct> </value> </fault> </methodResponse>
Advertisements